rem
stringlengths
1
53.3k
add
stringlengths
0
80.5k
context
stringlengths
6
326k
meta
stringlengths
141
403
input_ids
list
attention_mask
list
labels
list
run("./Array1.x10","Array1","./Constructs/Array"); }
runHelper(); }
public void test_Constructs_Array_Array1() { run("./Array1.x10","Array1","./Constructs/Array"); }
1769 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1769/3bd1027a0e8a0edbdacb19b952cc4296d36760df/TestCompiler.java/clean/x10.test/src/polyglot/ext/x10/tests/TestCompiler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1842, 67, 13262, 67, 1076, 67, 1076, 21, 1435, 288, 3639, 1086, 2932, 18, 19, 1076, 21, 18, 92, 2163, 15937, 1076, 21, 3113, 9654, 19, 13262, 19, 1076, 8863, 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, 1, 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, 1842, 67, 13262, 67, 1076, 67, 1076, 21, 1435, 288, 3639, 1086, 2932, 18, 19, 1076, 21, 18, 92, 2163, 15937, 1076, 21, 3113, 9654, 19, 13262, 19, 1076, 8863, 565, 289, 2, -...
int intValue = ( (BigDecimal) source ).intValue( );
int intValue = ( (Number) source ).intValue( );
public static Integer toInteger( Object source ) throws BirtException { if ( source == null ) return null; if ( source instanceof Integer ) { return (Integer) source; } else if ( source instanceof BigDecimal ) { int intValue = ( (BigDecimal) source ).intValue( ); return new Integer( intValue ); } else if ( source instanceof Boolean ) { if ( true == ( (Boolean) source ).booleanValue( ) ) return new Integer( 1 ); return new Integer( 0 ); } else if ( source instanceof Date ) { long longValue = ( (Date) source ).getTime( ); return new Integer( (int) longValue ); } else if ( source instanceof Double ) { int intValue = ( (Double) source ).intValue( ); return new Integer( intValue ); } else if ( source instanceof String ) { try { return new Integer(Double.valueOf((String) source).intValue()); } catch ( NumberFormatException e ) { throw new BirtException( pluginId, ResourceConstants.CONVERT_FAILS, new Object[]{ source.toString( ), "Integer" }, resourceBundle ); } } else { throw new BirtException( pluginId, ResourceConstants.CONVERT_FAILS, new Object[]{ source.toString( ), "Integer" }, resourceBundle ); } }
15160 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/15160/9851e5feb291170ea121e602b295bbaf81179a7d/DataTypeUtil.java/clean/core/org.eclipse.birt.core/src/org/eclipse/birt/core/data/DataTypeUtil.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 760, 2144, 358, 4522, 12, 1033, 1084, 262, 1216, 605, 2714, 503, 202, 95, 202, 202, 430, 261, 1084, 422, 446, 262, 1082, 202, 2463, 446, 31, 9506, 202, 430, 261, 1084, 1276, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2144, 358, 4522, 12, 1033, 1084, 262, 1216, 605, 2714, 503, 202, 95, 202, 202, 430, 261, 1084, 422, 446, 262, 1082, 202, 2463, 446, 31, 9506, 202, 430, 261, 1084, 1276, ...
if (policy.secureMethod == policy.ENCRYPT || policy.secureMethod == policy.SIGNENCRYPT) {
if (policy.secureMethod == SecureMethodParam.ENCRYPT || policy.secureMethod == SecureMethodParam.SIGNENCRYPT) {
public ProtectedMessageOutputStream(OutputStream stream, MessageAddress source, MessageAddress target, boolean encryptedSocket, boolean criticalPLevelMsg, ServiceBroker sb) throws GeneralSecurityException, IOException { super(stream); init(sb); if (_log.isInfoEnabled()) { _log.info("Sending Message: " + source + " -> " + target); } _source = source.toAddress(); _target = target.toAddress(); SecureMethodParam policy = _cps.getSendPolicy(_source, _target); // secret key encrypted by sender or receiver's certificate byte[] senderSecret = null; byte[] receiverSecret = null; if (policy == null) { dropMessage(); throw new IOException("This message was denied by policy. " + "There are no possible encryption algorithms " + "to send it."); } getCertificates(policy); SecretKey secret = null; if (_log.isDebugEnabled()) { _log.debug("Policy = " + policy); } policy = modifyPolicy(policy, encryptedSocket, criticalPLevelMsg); if (_log.isDebugEnabled()) { _log.debug("Modified policy = " + policy); } if (policy.secureMethod == policy.ENCRYPT || policy.secureMethod == policy.SIGNENCRYPT) { _encrypt = true; // first encrypt the secret key with the target's public key secret = _crypto.createSecretKey(policy.symmSpec); try { senderSecret = _crypto.encryptSecretKey(policy.asymmSpec, secret, _sourceCert); receiverSecret = _crypto.encryptSecretKey(policy.asymmSpec, secret, _targetCert); } catch (GeneralSecurityException e) { _log.error("Could not encrypt secret key. This message will not " + "go out properly! -- we'll retry later", e); throw new IOException(e.getMessage()); } } X509Certificate [] sourceChain = null; if (policy.secureMethod == policy.SIGNENCRYPT || policy.secureMethod == policy.SIGN) { _sign = true; } if ((_sign || _encrypt) && _sourceCert != null) { sourceChain = _keyRing.buildCertificateChain(_sourceCert); } ProtectedMessageHeader header = new ProtectedMessageHeader(sourceChain, _targetCert, policy, receiverSecret, senderSecret); if (_log.isDebugEnabled()) { _log.debug("Sending " + header); } ByteArrayOutputStream headerBytes = writeHeader(header); if (_encrypt) { _symmSpec = policy.symmSpec; _cipher = _crypto.getCipher(policy.symmSpec); _cipher.init(Cipher.ENCRYPT_MODE, secret); _cipherOut = new OnTopCipherOutputStream(this.out, _cipher); this.out = _cipherOut; } if (_sign) { if (_log.isInfoEnabled()) { _log.info("Still signing (" + _source + " -> " + _target + ") encrypted socket = " + encryptedSocket); } PrivateKey privateKey = getPrivateKey(_sourceCert); _signature = new SignatureOutputStream(this.out, policy.signSpec, privateKey); this.out = _signature; MessageDigest md = getMessageDigest(policy.signSpec); DigestOutputStream dout = new DigestOutputStream(new NullOutputStream(), md); headerBytes.writeTo(dout); dout.close(); write(md.digest()); } if (DUMP_MESSAGES) { String filename = getDumpFilename(); if (_log.isDebugEnabled()) { _log.debug("Dumping message content to file " + filename); } this.out = new DumpOutputStream(this.out, filename); } if (_log.isDebugEnabled()) { _log.debug("Stream from " + source + " to " + target + " ready!"); } }
12869 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12869/95ab7466f93a1698703219144f652cab9ff3c854/ProtectedMessageOutputStream.java/buggy/securityservices/src/org/cougaar/core/security/crypto/ProtectedMessageOutputStream.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 1186, 1050, 1079, 4632, 12, 4632, 1407, 16, 4766, 1377, 2350, 1887, 1084, 16, 4766, 1377, 2350, 1887, 1018, 16, 4766, 1377, 1250, 6901, 4534, 16, 4766, 1377, 1250, 11239, 52, 2355, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1186, 1050, 1079, 4632, 12, 4632, 1407, 16, 4766, 1377, 2350, 1887, 1084, 16, 4766, 1377, 2350, 1887, 1018, 16, 4766, 1377, 1250, 6901, 4534, 16, 4766, 1377, 1250, 11239, 52, 2355, ...
if (isTimeSet == false) {
if (!isTimeSet) {
protected long getTimeInMillis(){ if (isTimeSet == false) { computeTime(); } return (time);}
45713 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45713/86851d2ae0afc23f99aabd9afde1904686f08b67/Calendar.java/clean/libraries/javalib/java/util/Calendar.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4750, 1525, 6135, 16620, 1435, 95, 202, 430, 261, 291, 950, 694, 422, 629, 13, 288, 202, 202, 9200, 950, 5621, 202, 97, 202, 2463, 261, 957, 1769, 97, 2, 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, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4750, 1525, 6135, 16620, 1435, 95, 202, 430, 261, 291, 950, 694, 422, 629, 13, 288, 202, 202, 9200, 950, 5621, 202, 97, 202, 2463, 261, 957, 1769, 97, 2, -100, -100, -100, -100, -100, -100, ...
IPath path = folders[i].getLocation().append( fileName ); File file = new File( path.toOSString() ); if ( file.exists() ) { IFile[] wsFiles = CDebugCorePlugin.getWorkspace().getRoot().findFilesForLocation( path ); for ( int j = 0; j < wsFiles.length; ++j ) if ( wsFiles[j].exists() ) { if ( !searchForDuplicateFiles() ) return wsFiles[j]; list.add( wsFiles[j] ); }
IPath path = folders[i].getLocation(); if ( path != null ) { path = path.append( fileName ); File file = new File( path.toOSString() ); if ( file.exists() ) { IFile[] wsFiles = CDebugCorePlugin.getWorkspace().getRoot().findFilesForLocation( path ); for ( int j = 0; j < wsFiles.length; ++j ) if ( wsFiles[j].exists() ) { if ( !searchForDuplicateFiles() ) return wsFiles[j]; list.add( wsFiles[j] ); } }
private Object findFileByRelativePath( String fileName ) { IResource[] folders = getFolders(); LinkedList list = new LinkedList(); for ( int i = 0; i < folders.length; ++i ) { if ( list.size() > 0 && !searchForDuplicateFiles() ) break; IPath path = folders[i].getLocation().append( fileName ); File file = new File( path.toOSString() ); if ( file.exists() ) { IFile[] wsFiles = CDebugCorePlugin.getWorkspace().getRoot().findFilesForLocation( path ); for ( int j = 0; j < wsFiles.length; ++j ) if ( wsFiles[j].exists() ) { if ( !searchForDuplicateFiles() ) return wsFiles[j]; list.add( wsFiles[j] ); } } } return ( list.size() > 0 ) ? ( ( list.size() == 1 ) ? list.getFirst() : list ) : null; }
54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/1a8eee1a134b1eaa2da56eeba027acac6f27d691/CProjectSourceLocation.java/buggy/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/sourcelookup/CProjectSourceLocation.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 1033, 1104, 812, 858, 16519, 12, 514, 3968, 262, 202, 95, 202, 202, 45, 1420, 8526, 9907, 273, 2812, 4665, 5621, 202, 202, 13174, 682, 666, 273, 394, 10688, 5621, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 1033, 1104, 812, 858, 16519, 12, 514, 3968, 262, 202, 95, 202, 202, 45, 1420, 8526, 9907, 273, 2812, 4665, 5621, 202, 202, 13174, 682, 666, 273, 394, 10688, 5621, 202, 202, 1...
return Double.toString ((double) f, true);
return toString (value);
public static String toString (float f) { return Double.toString ((double) f, true); }
45163 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45163/9e55cc17c514e90df7d264f9fe0dd7b35dec9b46/Float.java/buggy/libjava/java/lang/Float.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 514, 1762, 261, 5659, 284, 13, 225, 288, 565, 327, 1762, 261, 1132, 1769, 225, 289, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 514, 1762, 261, 5659, 284, 13, 225, 288, 565, 327, 1762, 261, 1132, 1769, 225, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,...
return new BlobImpl(in);
return new BlobImpl(callerReference, in);
static Object readData(ResponseStream in, ColInfo ci, boolean readTextMode) throws IOException, ProtocolException { int len; switch (ci.tdsType) { case SYBINTN: switch (in.read()) { case 1: return new Byte((byte) in.read()); case 2: return new Short((short) in.readShort()); case 4: return new Integer(in.readInt()); case 8: return new Long(in.readLong()); } break; case SYBINT1: return new Byte((byte) in.read()); case SYBINT2: return new Short((short) in.readShort()); case SYBINT4: return new Integer(in.readInt()); case SYBINT8: return new Long(in.readLong()); case SYBIMAGE: len = in.read(); if (len > 0) { return new BlobImpl(in); } break; case SYBTEXT: len = in.read(); if (len > 0) { return new ClobImpl(in, false, readTextMode); } break; case SYBNTEXT: len = in.read(); if (len > 0) { return new ClobImpl(in, true, readTextMode); } break; case SYBCHAR: case SYBVARCHAR: len = in.read(); if (len == 1 && in.getTdsVersion() < TdsCore.TDS70) { // In TDS 4/5 zero length strings are stored as a single space // to distinguish them from nulls. String value = in.readAsciiString(len); return (value.equals(" ")) ? "" : value; } if (len > 0) { return in.readAsciiString(len); } break; case SYBNVARCHAR: len = in.read(); if (len > 0) { return in.readString(len / 2); } break; case XSYBCHAR: case XSYBVARCHAR: len = in.readShort(); if (len != -1) { return in.readAsciiString(len); } break; case XSYBNCHAR: case XSYBNVARCHAR: len = in.readShort(); if (len != -1) { return in.readString(len / 2); } break; case SYBVARBINARY: case SYBBINARY: len = in.read(); if (len > 0) { byte[] bytes = new byte[len]; in.read(bytes); return bytes; } break; case XSYBVARBINARY: case XSYBBINARY: len = in.readShort(); if (len != -1) { byte[] bytes = new byte[len]; in.read(bytes); return bytes; } break; case SYBMONEY4: case SYBMONEY: case SYBMONEYN: return getMoneyValue(in, ci.tdsType); case SYBDATETIME4: case SYBDATETIMN: case SYBDATETIME: return getDatetimeValue(in, ci.tdsType); case SYBBIT: return (in.read() != 0) ? Boolean.TRUE : Boolean.FALSE; case SYBBITN: len = in.read(); if (len > 0) { return (in.read() != 0) ? Boolean.TRUE : Boolean.FALSE; } break; case SYBREAL: return new Float(Float.intBitsToFloat(in.readInt())); case SYBFLT8: return new Double(Double.longBitsToDouble(in.readLong())); case SYBFLTN: len = in.read(); if (len == 4) { return new Float(Float.intBitsToFloat(in.readInt())); } else if (len == 8) { return new Double(Double.longBitsToDouble(in.readLong())); } break; case SYBUNIQUE: len = in.read(); if (len > 0) { byte[] bytes = new byte[len]; in.read(bytes); return new UniqueIdentifier(bytes); } break; case SYBNUMERIC: case SYBDECIMAL: len = in.read(); if (len > 0) { int sign = in.read(); len--; byte[] bytes = new byte[len]; BigInteger bi; if (in.getServerType() == TdsCore.SYBASE) { // Sybase order is MSB first! for (int i = 0; i < len; i++) { bytes[i] = (byte) in.read(); } bi = new BigInteger((sign == 0) ? 1 : -1, bytes); } else { while (len-- > 0) { bytes[len] = (byte)in.read(); } bi = new BigInteger((sign == 0) ? -1 : 1, bytes); } return new BigDecimal(bi, ci.scale); } break; case SYBVARIANT: return getVariant(in); default: throw new ProtocolException("Unsupported TDS data type 0x" + Integer.toHexString(ci.tdsType)); } return null; }
5753 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5753/56e9068ec616c6c95052dc39dce12c98471a778c/TdsData.java/clean/src/main/net/sourceforge/jtds/jdbc/TdsData.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 760, 1033, 20913, 12, 1064, 1228, 316, 16, 1558, 966, 9039, 16, 1250, 855, 1528, 2309, 13, 565, 1216, 1860, 16, 4547, 503, 288, 3639, 509, 562, 31, 3639, 1620, 261, 8450, 18, 88, 2377, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 20913, 12, 1064, 1228, 316, 16, 1558, 966, 9039, 16, 1250, 855, 1528, 2309, 13, 565, 1216, 1860, 16, 4547, 503, 288, 3639, 509, 562, 31, 3639, 1620, 261, 8450, 18, 88, 2377, ...
public Double getCredits() { double credits = getMasterDegreeServiceCredits(); credits += getTeachingDegreeCredits(); //credits += getPastServiceCredits(); credits += getOtherServiceCredits(); credits += getTeacherAdviseServiceCredits(); return round(credits); }
2645 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2645/d32c08f294ac2c3f8a390e1158cdb2e6ba43cafa/TeacherService.java/buggy/src/net/sourceforge/fenixedu/domain/teacher/TeacherService.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 3698, 1927, 1118, 1282, 1435, 288, 3639, 1645, 6197, 1282, 273, 27607, 22885, 1179, 24201, 1282, 5621, 3639, 6197, 1282, 1011, 3181, 13798, 310, 22885, 24201, 1282, 5621, 3639, 368, 206...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3698, 1927, 1118, 1282, 1435, 288, 3639, 1645, 6197, 1282, 273, 27607, 22885, 1179, 24201, 1282, 5621, 3639, 6197, 1282, 1011, 3181, 13798, 310, 22885, 24201, 1282, 5621, 3639, 368, 206...
private void displayBinding() {
private void displayBinding() {
private void displayBinding() { out.println("Avaialble variables in the current binding"); Binding context = shell.getContext(); Map variables = context.getVariables(); Set set = variables.keySet(); if (set.isEmpty()) { out.println("The current binding is empty."); } else { for (Iterator it = set.iterator(); it.hasNext();) { String key = (String)it.next(); out.println(key + " = " + variables.get(key)); } } }
6462 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6462/f8e7058e4da417dc2b5f0c3c1fab691b7c1e11d4/InteractiveShell.java/clean/src/main/groovy/ui/InteractiveShell.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 2562, 5250, 1435, 565, 288, 3639, 596, 18, 8222, 2932, 3769, 69, 649, 7119, 3152, 316, 326, 783, 5085, 8863, 3639, 15689, 819, 273, 5972, 18, 29120, 5621, 3639, 1635, 3152, 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, 918, 2562, 5250, 1435, 565, 288, 3639, 596, 18, 8222, 2932, 3769, 69, 649, 7119, 3152, 316, 326, 783, 5085, 8863, 3639, 15689, 819, 273, 5972, 18, 29120, 5621, 3639, 1635, 3152, 273...
final BaseInspectionVisitor visitor = createVisitor(mgr, isOnTheFly);
final BaseInspectionVisitor visitor = createVisitor(manager, isOnTheFly);
public ProblemDescriptor[] doCheckMethod(PsiMethod method, InspectionManager mgr, boolean isOnTheFly) { final PsiClass containingClass = method.getContainingClass(); if (containingClass == null) { return super.doCheckMethod(method, mgr, isOnTheFly); } if (!containingClass.isPhysical()) { return super.doCheckMethod(method, mgr, isOnTheFly); } final BaseInspectionVisitor visitor = createVisitor(mgr, isOnTheFly); method.accept(visitor); return visitor.getErrors(); }
56598 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56598/bd57f07c33c419f20715b114b71a7e93425b34c9/LocalVariableNamingConventionInspection.java/clean/plugins/InspectionGadgets/src/com/siyeh/ig/naming/LocalVariableNamingConventionInspection.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 21685, 3187, 8526, 741, 1564, 1305, 12, 52, 7722, 1305, 707, 16, 22085, 7017, 1318, 13333, 16, 1250, 28181, 1986, 42, 715, 13, 288, 3639, 727, 453, 7722, 797, 4191, 797, 273, 707, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 21685, 3187, 8526, 741, 1564, 1305, 12, 52, 7722, 1305, 707, 16, 22085, 7017, 1318, 13333, 16, 1250, 28181, 1986, 42, 715, 13, 288, 3639, 727, 453, 7722, 797, 4191, 797, 273, 707, ...
public static String getKind(File file) { String name = file.getName(); int dotIndex = name.lastIndexOf("."); String extension = null; if (dotIndex > 0) { extension = name.substring(dotIndex + 1, name.length()); } if (extension.equalsIgnoreCase("odf")) { OdfParser parser = new OdfParser(); OdfHandler handler = new OdfHandler(); FileInputStream fis = null; parser.setHandler(handler); try { fis = new FileInputStream(file); parser.parse(fis); } catch (Exception e) { } finally { try { if (fis != null) { fis.close(); } } catch (IOException x) { } } return handler.model; } else { return extension.toLowerCase(); } }
57344 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57344/0161c60988acd0837b7392536c3eb6d76fbbefc9/SemanticUtil.java/buggy/src/org/genepattern/util/SemanticUtil.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 3845, 780, 588, 5677, 12, 812, 768, 15329, 780, 529, 33, 768, 18, 17994, 5621, 474, 9811, 1016, 33, 529, 18, 2722, 31985, 2932, 1199, 1769, 780, 6447, 33, 2011, 31, 430, 12, 9811, 1016...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 3845, 780, 588, 5677, 12, 812, 768, 15329, 780, 529, 33, 768, 18, 17994, 5621, 474, 9811, 1016, 33, 529, 18, 2722, 31985, 2932, 1199, 1769, 780, 6447, 33, 2011, 31, 430, 12, 9811, 1016...
final PsiJavaToken sign = expression.getOperationSign(); if (sign == null) { return; }
public void visitBinaryExpression(PsiBinaryExpression expression) { super.visitBinaryExpression(expression); final PsiType expressionType = expression.getType(); if (expressionType == null) { return; } final PsiJavaToken sign = expression.getOperationSign(); if (sign == null) { return; } final PsiExpression rhs = expression.getROperand(); if (rhs == null) { return; } final PsiType rhsType = rhs.getType(); if (rhsType == null) { return; } if (rhsType.equals(PsiType.BOOLEAN) || "java.lang.Boolean".equals(rhsType.getCanonicalText())) { return; } final PsiExpression lhs = expression.getLOperand(); if (lhs == null) { return; } final PsiType lhsType = lhs.getType(); if (lhsType == null) { return; } if (lhsType.equals(PsiType.BOOLEAN) || "java.lang.Boolean".equals(lhsType.getCanonicalText())) { return; } final IElementType tokenType = sign.getTokenType(); final boolean isPointless; if (tokenType.equals(JavaTokenType.AND)) { isPointless = andExpressionIsPointless(lhs, rhs, expressionType); } else if (tokenType.equals(JavaTokenType.OR)) { isPointless = orExpressionIsPointless(lhs, rhs, expressionType); } else if (tokenType.equals(JavaTokenType.XOR)) { isPointless = xorExpressionIsPointless(lhs, rhs, expressionType); } else if (tokenType.equals(JavaTokenType.LTLT) || tokenType.equals(JavaTokenType.GTGT) || tokenType.equals(JavaTokenType.GTGTGT)) { isPointless = shiftExpressionIsPointless(rhs, expressionType); } else { isPointless = false; } if (!isPointless) { return; } registerError(expression); }
56598 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56598/dba8b183fc1b08e7ad664812bfc0c64d1e4abd3c/PointlessBitwiseExpressionInspection.java/clean/plugins/InspectionGadgets/src/com/siyeh/ig/verbose/PointlessBitwiseExpressionInspection.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 1071, 918, 3757, 5905, 2300, 12, 52, 7722, 5905, 2300, 2652, 13, 288, 5411, 2240, 18, 11658, 5905, 2300, 12, 8692, 1769, 5411, 727, 453, 7722, 559, 2652, 559, 273, 2652, 18, 588, 559, 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, 540, 1071, 918, 3757, 5905, 2300, 12, 52, 7722, 5905, 2300, 2652, 13, 288, 5411, 2240, 18, 11658, 5905, 2300, 12, 8692, 1769, 5411, 727, 453, 7722, 559, 2652, 559, 273, 2652, 18, 588, 559, 5...
private static void generateCtor(ClassFileWriter cfw, String genName, Class superClass) { cfw.startMethod("<init>", "(Lorg/mozilla/javascript/FlattenedObject;)V", ClassFileWriter.ACC_PUBLIC); // Invoke base class constructor cfw.add(ByteCode.ALOAD_0); // this cfw.add(ByteCode.INVOKESPECIAL, superClass.getName().replace('.', '/'), "<init>", "()", "V"); // save parameter in instance variable cfw.add(ByteCode.ALOAD_0); // this cfw.add(ByteCode.ALOAD_1); // first arg cfw.add(ByteCode.PUTFIELD, genName, "o", "Lorg/mozilla/javascript/FlattenedObject;"); // store Scriptable object in "self" a public instance variable, so scripts can read it. cfw.add(ByteCode.ALOAD_0); // this cfw.add(ByteCode.ALOAD_1); // first arg cfw.add(ByteCode.INVOKEVIRTUAL, "org/mozilla/javascript/FlattenedObject", "getObject", "()", "Lorg/mozilla/javascript/Scriptable;"); cfw.add(ByteCode.PUTFIELD, genName, "self", "Lorg/mozilla/javascript/Scriptable;"); cfw.add(ByteCode.RETURN); cfw.stopMethod((short)20, null); // TODO: magic number "20" }
7555 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7555/eb9dcf8b50d68e0bd092a827fa5808d341974237/JavaAdapter.java/buggy/js/rhino/org/mozilla/javascript/JavaAdapter.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 760, 918, 2103, 27425, 12, 797, 812, 2289, 6080, 91, 16, 514, 3157, 461, 16, 4766, 1377, 1659, 18846, 13, 377, 288, 3639, 6080, 91, 18, 1937, 1305, 2932, 32, 2738, 2984, 16, 7682,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 760, 918, 2103, 27425, 12, 797, 812, 2289, 6080, 91, 16, 514, 3157, 461, 16, 4766, 1377, 1659, 18846, 13, 377, 288, 3639, 6080, 91, 18, 1937, 1305, 2932, 32, 2738, 2984, 16, 7682,...
Vector clones = new Vector();
Vector clones = (null != m_waiting) ? new Vector() : null;
public Object clone() throws CloneNotSupportedException { LocPathIterator clone = (LocPathIterator) super.clone();// clone.m_varStackPos = this.m_varStackPos;// clone.m_varStackContext = this.m_varStackContext; if (null != m_firstWalker) { Vector clones = new Vector(); // yuck clone.m_firstWalker = m_firstWalker.cloneDeep(clone, clones); if(null != m_waiting) { clone.m_waiting = (Vector)m_waiting.clone(); // or is new Vector faster? int n = m_waiting.size(); for (int i = 0; i < n; i++) { AxesWalker waiting = (AxesWalker)m_waiting.elementAt(i); clone.m_waiting.setElementAt(waiting.cloneDeep(clone, clones), i); } } if(null != m_lastUsedWalker) clone.m_lastUsedWalker = m_lastUsedWalker.cloneDeep(clone, clones); } return clone; }
2723 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2723/ae559776b6bade54360096b41763bbb47f9ba793/LocPathIterator.java/clean/src/org/apache/xpath/axes/LocPathIterator.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 1033, 3236, 1435, 1216, 12758, 25482, 225, 288, 3639, 2851, 743, 3198, 3236, 273, 261, 1333, 743, 3198, 13, 2240, 18, 14056, 5621, 759, 565, 3236, 18, 81, 67, 1401, 2624, 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, 282, 1071, 1033, 3236, 1435, 1216, 12758, 25482, 225, 288, 3639, 2851, 743, 3198, 3236, 273, 261, 1333, 743, 3198, 13, 2240, 18, 14056, 5621, 759, 565, 3236, 18, 81, 67, 1401, 2624, 1616, 273,...
public List constraints() throws RecognitionException { List constraints; constraints = new ArrayList(); try { // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:653:17: ( opt_eol ( constraint[constraints] | predicate[constraints] ) ( opt_eol ',' opt_eol ( constraint[constraints] | predicate[constraints] ) )* opt_eol ) // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:653:17: opt_eol ( constraint[constraints] | predicate[constraints] ) ( opt_eol ',' opt_eol ( constraint[constraints] | predicate[constraints] ) )* opt_eol { following.push(FOLLOW_opt_eol_in_constraints1628); opt_eol(); following.pop(); // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:654:17: ( constraint[constraints] | predicate[constraints] ) int alt46=2; int LA46_0 = input.LA(1); if ( LA46_0==EOL||LA46_0==15 ) { alt46=1; } else if ( LA46_0==ID ) { int LA46_2 = input.LA(2); if ( LA46_2==30 ) { int LA46_3 = input.LA(3); if ( LA46_3==ID ) { int LA46_8 = input.LA(4); if ( LA46_8==50 ) { alt46=2; } else if ( LA46_8==EOL||LA46_8==15||(LA46_8>=22 && LA46_8<=23)||(LA46_8>=40 && LA46_8<=47) ) { alt46=1; } else { NoViableAltException nvae = new NoViableAltException("654:17: ( constraint[constraints] | predicate[constraints] )", 46, 8, input); throw nvae; } } else if ( LA46_3==EOL||LA46_3==15 ) { alt46=1; } else { NoViableAltException nvae = new NoViableAltException("654:17: ( constraint[constraints] | predicate[constraints] )", 46, 3, input); throw nvae; } } else if ( LA46_2==EOL||LA46_2==15||(LA46_2>=22 && LA46_2<=23)||(LA46_2>=40 && LA46_2<=47) ) { alt46=1; } else { NoViableAltException nvae = new NoViableAltException("654:17: ( constraint[constraints] | predicate[constraints] )", 46, 2, input); throw nvae; } } else { NoViableAltException nvae = new NoViableAltException("654:17: ( constraint[constraints] | predicate[constraints] )", 46, 0, input); throw nvae; } switch (alt46) { case 1 : // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:654:18: constraint[constraints] { following.push(FOLLOW_constraint_in_constraints1633); constraint(constraints); following.pop(); } break; case 2 : // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:654:42: predicate[constraints] { following.push(FOLLOW_predicate_in_constraints1636); predicate(constraints); following.pop(); } break; } // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:655:17: ( opt_eol ',' opt_eol ( constraint[constraints] | predicate[constraints] ) )* loop48: do { int alt48=2; alt48 = dfa48.predict(input); switch (alt48) { case 1 : // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:655:19: opt_eol ',' opt_eol ( constraint[constraints] | predicate[constraints] ) { following.push(FOLLOW_opt_eol_in_constraints1644); opt_eol(); following.pop(); match(input,22,FOLLOW_22_in_constraints1646); following.push(FOLLOW_opt_eol_in_constraints1648); opt_eol(); following.pop(); // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:655:39: ( constraint[constraints] | predicate[constraints] ) int alt47=2; int LA47_0 = input.LA(1); if ( LA47_0==EOL||LA47_0==15 ) { alt47=1; } else if ( LA47_0==ID ) { int LA47_2 = input.LA(2); if ( LA47_2==30 ) { int LA47_3 = input.LA(3); if ( LA47_3==ID ) { int LA47_8 = input.LA(4); if ( LA47_8==50 ) { alt47=2; } else if ( LA47_8==EOL||LA47_8==15||(LA47_8>=22 && LA47_8<=23)||(LA47_8>=40 && LA47_8<=47) ) { alt47=1; } else { NoViableAltException nvae = new NoViableAltException("655:39: ( constraint[constraints] | predicate[constraints] )", 47, 8, input); throw nvae; } } else if ( LA47_3==EOL||LA47_3==15 ) { alt47=1; } else { NoViableAltException nvae = new NoViableAltException("655:39: ( constraint[constraints] | predicate[constraints] )", 47, 3, input); throw nvae; } } else if ( LA47_2==EOL||LA47_2==15||(LA47_2>=22 && LA47_2<=23)||(LA47_2>=40 && LA47_2<=47) ) { alt47=1; } else { NoViableAltException nvae = new NoViableAltException("655:39: ( constraint[constraints] | predicate[constraints] )", 47, 2, input); throw nvae; } } else { NoViableAltException nvae = new NoViableAltException("655:39: ( constraint[constraints] | predicate[constraints] )", 47, 0, input); throw nvae; } switch (alt47) { case 1 : // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:655:40: constraint[constraints] { following.push(FOLLOW_constraint_in_constraints1651); constraint(constraints); following.pop(); } break; case 2 : // /Users/bob/checkouts/jbossrules/drools-compiler/src/main/resources/org/drools/lang/drl.g:655:64: predicate[constraints] { following.push(FOLLOW_predicate_in_constraints1654); predicate(constraints); following.pop(); } break; } } break; default : break loop48; } } while (true); following.push(FOLLOW_opt_eol_in_constraints1662); opt_eol(); following.pop(); } } catch (RecognitionException re) { reportError(re); recover(input,re); } finally { } return constraints; }
6736 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6736/f206af510f937d389fa71f33abed691ac65aa4e3/RuleParser.java/clean/drools-compiler/src/main/java/org/drools/lang/RuleParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 987, 6237, 1435, 1216, 9539, 288, 6647, 987, 6237, 31, 540, 202, 202, 11967, 273, 394, 2407, 5621, 540, 202, 3639, 775, 288, 5411, 368, 342, 6588, 19, 70, 947, 19, 17300, 87, 19, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 987, 6237, 1435, 1216, 9539, 288, 6647, 987, 6237, 31, 540, 202, 202, 11967, 273, 394, 2407, 5621, 540, 202, 3639, 775, 288, 5411, 368, 342, 6588, 19, 70, 947, 19, 17300, 87, 19, ...
previousFeatures = null;
Set previousFeatures = null;
private void initializeFeatureSets() { Assert.isTrue(currentFeatures == null); // retrieve list of installed feature from last session IDialogSettings settings = IDEWorkbenchPlugin.getDefault().getDialogSettings(); String[] previousFeaturesArray = settings.getArray(INSTALLED_FEATURES); previousFeatures = null; if (previousFeaturesArray != null) { previousFeatures = new HashSet(Arrays.asList(previousFeaturesArray)); } else { previousFeatures = new HashSet(0); } // store list of installed features for next session currentFeatures = computeFeatureSet(); String[] currentFeaturesArray = new String[currentFeatures.size()]; currentFeatures.toArray(currentFeaturesArray); settings.put(INSTALLED_FEATURES, currentFeaturesArray); // compute recently installed features - use TreeSet to get predictable order newlyAddedFeatures = new TreeSet(currentFeatures); newlyAddedFeatures.removeAll(previousFeatures); }
56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/1cbee43cfab5af4b895417b187eacf1e43b7ada9/IDEWorkbenchAdvisor.java/buggy/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/IDEWorkbenchAdvisor.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 4046, 4595, 2785, 1435, 288, 202, 202, 8213, 18, 291, 5510, 12, 2972, 8696, 422, 446, 1769, 9506, 202, 759, 4614, 666, 434, 5876, 2572, 628, 1142, 1339, 1082, 202, 734, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4046, 4595, 2785, 1435, 288, 202, 202, 8213, 18, 291, 5510, 12, 2972, 8696, 422, 446, 1769, 9506, 202, 759, 4614, 666, 434, 5876, 2572, 628, 1142, 1339, 1082, 202, 734, ...
private boolean getCatchClauseToThrowsProposals(IAssistContext context, ASTNode node, Collection resultingCollections) throws CoreException {
private boolean getCatchClauseToThrowsProposals(IInvocationContext context, ASTNode node, Collection resultingCollections) throws CoreException {
private boolean getCatchClauseToThrowsProposals(IAssistContext context, ASTNode node, Collection resultingCollections) throws CoreException { CatchClause catchClause= (CatchClause) ASTResolving.findAncestor(node, ASTNode.CATCH_CLAUSE); if (catchClause == null) { return false; } Type type= catchClause.getException().getType(); if (!type.isSimpleType()) { return false; } BodyDeclaration bodyDeclaration= ASTResolving.findParentBodyDeclaration(catchClause); if (!(bodyDeclaration instanceof MethodDeclaration)) { return false; } if (resultingCollections == null) { return true; } MethodDeclaration methodDeclaration= (MethodDeclaration) bodyDeclaration; ASTRewrite rewrite= new ASTRewrite(methodDeclaration); AST ast= methodDeclaration.getAST(); TryStatement tryStatement= (TryStatement) catchClause.getParent(); if (tryStatement.catchClauses().size() > 1 || tryStatement.getFinally() != null) { rewrite.markAsRemoved(catchClause); } else { List statements= tryStatement.getBody().statements(); if (statements.size() > 0) { ASTNode placeholder= rewrite.collapseNodes(statements, 0, statements.size()); rewrite.markAsReplaced(tryStatement, rewrite.createCopy(placeholder)); } else { rewrite.markAsRemoved(tryStatement); } } ITypeBinding binding= type.resolveBinding(); if (binding == null || isNotYetThrown(binding, methodDeclaration.thrownExceptions())) { Name name= ((SimpleType) type).getName(); Name newName= (Name) ASTNode.copySubtree(ast, name); rewrite.markAsInserted(newName); methodDeclaration.thrownExceptions().add(newName); } String label= CorrectionMessages.getString("QuickAssistProcessor.catchclausetothrows.description"); //$NON-NLS-1$ Image image= JavaPluginImages.get(JavaPluginImages.IMG_OBJS_EXCEPTION); ASTRewriteCorrectionProposal proposal= new ASTRewriteCorrectionProposal(label, context.getCompilationUnit(), rewrite, 1, image); proposal.ensureNoModifications(); resultingCollections.add(proposal); return true; }
9698 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9698/743c8e3c183622ead26220802483db7fbb3772ab/QuickAssistProcessor.java/buggy/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/correction/QuickAssistProcessor.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 1250, 1927, 505, 7044, 774, 21845, 626, 22536, 12, 45, 2610, 376, 1042, 819, 16, 9183, 907, 756, 16, 2200, 8156, 15150, 13, 1216, 30015, 288, 202, 202, 14842, 7044, 1044, 7044,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1927, 505, 7044, 774, 21845, 626, 22536, 12, 45, 2610, 376, 1042, 819, 16, 9183, 907, 756, 16, 2200, 8156, 15150, 13, 1216, 30015, 288, 202, 202, 14842, 7044, 1044, 7044,...
else { lastKid = index; index = kidMatch; }
if (state.goForBroke && (state.complete != -1)) return state.complete; lastKid = index; index = kidMatch;
int matchRENodes(MatchState state, RENode ren, RENode stop, int index) { int num; char[] input = state.input; while ((ren != stop) && (ren != null)) { switch (ren.op) { case REOP_EMPTY: break; case REOP_ALT: { if (ren.next.op != REOP_ALT) { ren = (RENode)ren.kid; continue; } else { num = state.parenCount; int kidMatch = matchRENodes(state, (RENode)ren.kid, stop, index); if (kidMatch != -1) return kidMatch; for (int i = num; i < state.parenCount; i++) state.parens[i] = null; state.parenCount = num; } } break; case REOP_QUANT: { int lastKid = -1; for (num = 0; num < ren.min; num++) { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) return -1; else { lastKid = index; index = kidMatch; } } if (num == ren.max) // Have matched the exact count required, // need to match the rest of the regexp. break; if ((ren.flags & RENode.MINIMAL) == 0) { int kidMatch = matchGreedyKid(state, ren, stop, num, index, lastKid); if (kidMatch == -1) index = matchRENodes(state, (RENode)ren.kid, ren.next, index); else index = kidMatch; } else { index = matchNonGreedyKid(state, ren, num, ren.max, index); } if (index == -1) return -1; } break; case REOP_PLUS: { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) return -1; if ((ren.flags & RENode.MINIMAL) == 0) { kidMatch = matchGreedyKid(state, ren, stop, 1, kidMatch, index); if (kidMatch == -1) index = matchRENodes(state,(RENode)ren.kid, ren.next, index); else index = kidMatch; } else index = matchNonGreedyKid(state, ren, 1, 0, kidMatch); if (index == -1) return -1; } break; case REOP_STAR: if ((ren.flags & RENode.MINIMAL) == 0) { int kidMatch = matchGreedyKid(state, ren, stop, 0, index, -1); if (kidMatch != -1) index = kidMatch; } else { index = matchNonGreedyKid(state, ren, 0, 0, index); if (index == -1) return -1; } break; case REOP_OPT: { int saveNum = state.parenCount; if (((ren.flags & RENode.MINIMAL) != 0)) { int restMatch = matchRENodes(state, ren.next, stop, index); if (restMatch != -1) return restMatch; } int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) { state.parenCount = saveNum; break; } else { int restMatch = matchRENodes(state, ren.next, stop, kidMatch); if (restMatch == -1) { // need to undo the result of running the kid state.parenCount = saveNum; break; } else return restMatch; } } case REOP_LPARENNON: ren = (RENode)ren.kid; continue; case REOP_RPARENNON: break; case REOP_LPAREN: { num = ren.num; ren = (RENode)ren.kid; SubString parsub = state.parens[num]; if (parsub == null) { parsub = state.parens[num] = new SubString(); parsub.charArray = input; } parsub.index = index; parsub.length = 0; if (num >= state.parenCount) state.parenCount = num + 1; continue; } case REOP_RPAREN: { num = ren.num; SubString parsub = state.parens[num]; if (parsub == null) throw new RuntimeException("Paren problem"); parsub.length = index - parsub.index; break; } case REOP_ASSERT: { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) return -1; break; } case REOP_ASSERT_NOT: { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch != -1) return -1; break; } case REOP_BACKREF: { num = ren.num; if (num >= state.parens.length) { Context.reportError( ScriptRuntime.getMessage( "msg.bad.backref", null)); return -1; } SubString parsub = state.parens[num]; if (parsub == null) parsub = state.parens[num] = new SubString(); int length = parsub.length; for (int i = 0; i < length; i++, index++) { if (index >= input.length) { return state.noMoreInput(); } if (!matchChar(state.flags, input[index], parsub.charArray[parsub.index + i])) return -1; } } break; case REOP_CCLASS: if (index >= input.length) { return state.noMoreInput(); } if (ren.bitmap == null) { char[] source = (ren.s != null) ? ren.s : this.source.toCharArray(); ren.buildBitmap(state, source, ((state.flags & FOLD) != 0)); } char c = input[index]; int b = (c >>> 3); if (b >= ren.bmsize) { if (ren.kid2 == -1) // a ^ class index++; else return -1; } else { int bit = c & 7; bit = 1 << bit; if ((ren.bitmap[b] & bit) != 0) index++; else return -1; } break; case REOP_DOT: if (index >= input.length) { return state.noMoreInput(); } if (input[index] != '\n') index++; else return -1; break; case REOP_DOTSTARMIN: { int cp2; for (cp2 = index; cp2 < input.length; cp2++) { int cp3 = matchRENodes(state, ren.next, stop, cp2); if (cp3 != -1) return cp3; if (input[cp2] == '\n') return -1; } return state.noMoreInput(); } case REOP_DOTSTAR: { int cp2; for (cp2 = index; cp2 < input.length; cp2++) if (input[cp2] == '\n') break; while (cp2 >= index) { int cp3 = matchRENodes(state, ren.next, stop, cp2); if (cp3 != -1) { index = cp2; break; } cp2--; } break; } case REOP_WBDRY: if (index == 0 || !isWord(input[index-1])) { if (index >= input.length) return state.noMoreInput(); if (!isWord(input[index])) return -1; } else { if (index < input.length && isWord(input[index])) return -1; } break; case REOP_WNONBDRY: if (index == 0 || !isWord(input[index-1])) { if (index < input.length && isWord(input[index])) return -1; } else { if (index >= input.length) return state.noMoreInput(); if (!isWord(input[index])) return -1; } break; case REOP_EOLONLY: case REOP_EOL: { if (index == input.length) ; // leave index; else { Context cx = Context.getCurrentContext(); RegExpImpl reImpl = getImpl(cx); if ((reImpl.multiline) || ((state.flags & MULTILINE) != 0)) if (input[index] == '\n') ;// leave index else return -1; else return -1; } } break; case REOP_BOL: { Context cx = Context.getCurrentContext(); RegExpImpl reImpl = getImpl(cx); if (index != 0) { if (reImpl.multiline || ((state.flags & MULTILINE) != 0)) { if (index >= input.length) { return state.noMoreInput(); } if (input[index - 1] == '\n') { break; } } return -1; } // leave index } break; case REOP_DIGIT: if (index >= input.length) { return state.noMoreInput(); } if (!isDigit(input[index])) return -1; index++; break; case REOP_NONDIGIT: if (index >= input.length) { return state.noMoreInput(); } if (isDigit(input[index])) return -1; index++; break; case REOP_ALNUM: if (index >= input.length) { return state.noMoreInput(); } if (!isWord(input[index])) return -1; index++; break; case REOP_NONALNUM: if (index >= input.length) { return state.noMoreInput(); } if (isWord(input[index])) return -1; index++; break; case REOP_SPACE: if (index >= input.length) { return state.noMoreInput(); } if (!(TokenStream.isJSSpace(input[index]) || TokenStream.isJSLineTerminator(input[index]))) return -1; index++; break; case REOP_NONSPACE: if (index >= input.length) { return state.noMoreInput(); } if (TokenStream.isJSSpace(input[index]) || TokenStream.isJSLineTerminator(input[index])) return -1; index++; break; case REOP_FLAT1: if (index >= input.length) { return state.noMoreInput(); } if (!matchChar(state.flags, ren.chr, input[index])) return -1; index++; break; case REOP_FLAT: { char[] source = (ren.s != null) ? ren.s : this.source.toCharArray(); int start = ((Integer)ren.kid).intValue(); int length = ren.kid2 - start; for (int i = 0; i < length; i++, index++) { if (index >= input.length) { return state.noMoreInput(); } if (!matchChar(state.flags, input[index], source[start + i])) return -1; } } break; case REOP_JUMP: break; case REOP_END: break; default : throw new RuntimeException("Unsupported by node matcher"); } ren = ren.next; } return index; }
51275 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51275/b16d847568c4b6033672534e58b050c4923f9c31/NativeRegExp.java/buggy/js/rhino/src/org/mozilla/javascript/regexp/NativeRegExp.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 509, 845, 862, 3205, 12, 2060, 1119, 919, 16, 2438, 907, 1654, 16, 2438, 907, 2132, 16, 509, 770, 13, 288, 3639, 509, 818, 31, 3639, 1149, 8526, 810, 273, 919, 18, 2630, 31, 3639, 132...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 509, 845, 862, 3205, 12, 2060, 1119, 919, 16, 2438, 907, 1654, 16, 2438, 907, 2132, 16, 509, 770, 13, 288, 3639, 509, 818, 31, 3639, 1149, 8526, 810, 273, 919, 18, 2630, 31, 3639, 132...
Account from, Account to, EntryType entryType, BigDecimal amount, PaymentMode paymentMode, DateTime whenRegistered) { return new AccountingTransaction(responsibleUser, event, makeEntry(entryType, amount.negate(), from), makeEntry(entryType, amount, to), paymentMode, whenRegistered);
Account from, Account to, EntryType entryType, BigDecimal amount, PaymentMode paymentMode, DateTime whenRegistered) { return new AccountingTransaction(responsibleUser, event, makeEntry(entryType, amount.negate(), from), makeEntry(entryType, amount, to), paymentMode, whenRegistered);
protected AccountingTransaction makeAccountingTransaction(User responsibleUser, Event event, Account from, Account to, EntryType entryType, BigDecimal amount, PaymentMode paymentMode, DateTime whenRegistered) { return new AccountingTransaction(responsibleUser, event, makeEntry(entryType, amount.negate(), from), makeEntry(entryType, amount, to), paymentMode, whenRegistered); }
2645 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2645/119799af80bf5fcb84b46d31241d6fb85fb7298b/PostingRule.java/clean/src/net/sourceforge/fenixedu/domain/accounting/PostingRule.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4750, 6590, 310, 3342, 1221, 3032, 310, 3342, 12, 1299, 14549, 1299, 16, 2587, 871, 16, 5411, 6590, 628, 16, 6590, 358, 16, 3841, 559, 1241, 559, 16, 8150, 3844, 16, 12022, 2309, 5184, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6590, 310, 3342, 1221, 3032, 310, 3342, 12, 1299, 14549, 1299, 16, 2587, 871, 16, 5411, 6590, 628, 16, 6590, 358, 16, 3841, 559, 1241, 559, 16, 8150, 3844, 16, 12022, 2309, 5184, ...
public Tag createTag() {
public Tag createTag(String name, Attributes attributes) {
public Tag createTag() { return new TargetTag(); }
51800 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51800/b6602aaf4d7208bb6da73dca5bde745e332b0fa6/JeezTagLibrary.java/buggy/src/java/org/apache/commons/jelly/tags/jeez/JeezTagLibrary.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 5397, 1071, 4034, 752, 1805, 12, 780, 508, 16, 9055, 1677, 13, 288, 13491, 327, 394, 5916, 1805, 5621, 10792, 289, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 5397, 1071, 4034, 752, 1805, 12, 780, 508, 16, 9055, 1677, 13, 288, 13491, 327, 394, 5916, 1805, 5621, 10792, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...
catch (java.io.IOException e) { --bufpos; backup(0); if (tokenBegin == -1) { tokenBegin = bufpos; } throw e; } }
else maxNextCharInd += i; return; } catch(java.io.IOException e) { --bufpos; backup(0); if (tokenBegin == -1) tokenBegin = bufpos; throw e; } }
protected void FillBuff() throws java.io.IOException { if (maxNextCharInd == available) { if (available == bufsize) { if (tokenBegin > 2048) { bufpos = maxNextCharInd = 0; available = tokenBegin; } else if (tokenBegin < 0) { bufpos = maxNextCharInd = 0; } else { ExpandBuff(false); } } else if (available > tokenBegin) { available = bufsize; } else if ((tokenBegin - available) < 2048) { ExpandBuff(true); } else { available = tokenBegin; } } int i; try { if ((i = inputStream.read( buffer, maxNextCharInd, available - maxNextCharInd )) == -1) { inputStream.close(); throw new java.io.IOException(); } else { maxNextCharInd += i; } return; } catch (java.io.IOException e) { --bufpos; backup(0); if (tokenBegin == -1) { tokenBegin = bufpos; } throw e; } }
7954 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7954/45c7db5b9c3d703ed4fabee51cebb349a8ffec67/SimpleCharStream.java/buggy/aspectwerkz2/src/main/org/codehaus/aspectwerkz/definition/expression/ast/SimpleCharStream.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4750, 918, 14192, 10642, 1435, 1216, 2252, 18, 1594, 18, 14106, 288, 3639, 309, 261, 1896, 2134, 2156, 3866, 422, 2319, 13, 288, 5411, 309, 261, 5699, 422, 1681, 1467, 13, 288, 7734, 309,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 14192, 10642, 1435, 1216, 2252, 18, 1594, 18, 14106, 288, 3639, 309, 261, 1896, 2134, 2156, 3866, 422, 2319, 13, 288, 5411, 309, 261, 5699, 422, 1681, 1467, 13, 288, 7734, 309,...
if (user.indexOf("@") < 0) { user = user + defaultSuffix; } LOG.debug("User not found in email map. Mailing to: " + user); emails.add(user);
mappedUser = user;
protected String createUserList(XMLLogHelper logHelper) throws CruiseControlException { Set users = logHelper.getBuildParticipants(); if (skipUsers) { users = new HashSet(); } //add always addresses for (int i = 0; i < alwaysAddresses.length; i++) { users.add(alwaysAddresses[i].getAddress()); } //if build failed, add failure addresses if (!logHelper.isBuildSuccessful()) { for (int i = 0; i < failureAddresses.length; i++) { users.add(failureAddresses[i].getAddress()); } } //If build fixed, add failure addresses that want to know about the fix if (logHelper.isBuildFix()) { for (int i = 0; i < failureAddresses.length; i++) { if (failureAddresses[i].shouldReportWhenFixed()) { users.add(failureAddresses[i].getAddress()); } } } //if build succeeded, add success addresses if (logHelper.isBuildSuccessful()) { for (int i = 0; i < successAddresses.length; i++) { users.add(successAddresses[i].getAddress()); } } //move map to hashtable Set emails = new TreeSet(); Hashtable emailMappings = new Hashtable(); for (int i = 0; i < emailMap.length; i++) { EmailMapping mapping = emailMap[i]; LOG.debug( "Mapping alias: " + mapping.getAlias() + " to address: " + mapping.getAddress()); emailMappings.put(mapping.getAlias(), mapping.getAddress()); } Iterator userIterator = users.iterator(); while (userIterator.hasNext()) { String user = (String) userIterator.next(); if (emailMappings.containsKey(user)) { LOG.debug("User found in email map. Mailing to: " + emailMappings.get(user)); emails.add(emailMappings.get(user)); } else { if (user.indexOf("@") < 0) { user = user + defaultSuffix; } LOG.debug("User not found in email map. Mailing to: " + user); emails.add(user); } } //return set of emails as a comma delimited string StringBuffer commaDelimitedString = new StringBuffer(); int emailCount = 1; Iterator emailIterator = emails.iterator(); while (emailIterator.hasNext()) { commaDelimitedString.append((String) emailIterator.next()); if (emailCount < emails.size()) { commaDelimitedString.append(","); } emailCount++; } LOG.debug("Final list of emails: " + commaDelimitedString.toString()); return commaDelimitedString.toString(); }
55334 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55334/da5374260c53b5c305e38f11aa1a482ed51c3304/EmailPublisher.java/buggy/main/src/net/sourceforge/cruisecontrol/publishers/EmailPublisher.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4750, 514, 22992, 682, 12, 4201, 1343, 2276, 613, 2276, 13, 5411, 1216, 385, 8653, 784, 3367, 503, 288, 3639, 1000, 3677, 273, 613, 2276, 18, 588, 3116, 1988, 27620, 5621, 3639, 309, 261,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 22992, 682, 12, 4201, 1343, 2276, 613, 2276, 13, 5411, 1216, 385, 8653, 784, 3367, 503, 288, 3639, 1000, 3677, 273, 613, 2276, 18, 588, 3116, 1988, 27620, 5621, 3639, 309, 261,...
public synchronized void jobHasFinished() throws IOException { if (getRunState() == TaskStatus.State.RUNNING) {
public void jobHasFinished() throws IOException { boolean killTask = false; synchronized(this){ killTask = (getRunState() == TaskStatus.State.RUNNING); if (killTask) {
public synchronized void jobHasFinished() throws IOException { if (getRunState() == TaskStatus.State.RUNNING) { killAndCleanup(false); } else { cleanup(); } if (keepJobFiles) return; // Delete temp directory in case any task used PhasedFileSystem. try{ String systemDir = task.getConf().get("mapred.system.dir"); Path taskTempDir = new Path(systemDir + "/" + task.getJobId() + "/" + task.getTipId()); if( fs.exists(taskTempDir)){ fs.delete(taskTempDir) ; } }catch(IOException e){ LOG.warn("Error in deleting reduce temporary output",e); } // Delete the job directory for this // task if the job is done/failed if (purgeJobFiles) { this.defaultJobConf.deleteLocalFiles(SUBDIR + Path.SEPARATOR + JOBCACHE + Path.SEPARATOR + task.getJobId()); } }
48130 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48130/397e2b6c9d26c4f27b8d55ac61dae87d68ba1a0f/TaskTracker.java/buggy/src/java/org/apache/hadoop/mapred/TaskTracker.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 1071, 3852, 918, 1719, 5582, 10577, 1435, 1216, 1860, 288, 540, 202, 2398, 309, 261, 588, 1997, 1119, 1435, 422, 29628, 18, 1119, 18, 29358, 13, 288, 7734, 8673, 1876, 15007, 12, 5743, 17...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 1071, 3852, 918, 1719, 5582, 10577, 1435, 1216, 1860, 288, 540, 202, 2398, 309, 261, 588, 1997, 1119, 1435, 422, 29628, 18, 1119, 18, 29358, 13, 288, 7734, 8673, 1876, 15007, 12, 5743, 17...
public String getEncoding() throws SQLException {
public Encoding getEncoding() throws SQLException {
public String getEncoding() throws SQLException { return encoding; }
52628 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52628/ff21a8e5c86457e205ff7c598b930efd711cb2dc/Connection.java/clean/src/interfaces/jdbc/org/postgresql/Connection.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 13400, 29505, 1435, 1216, 6483, 288, 3639, 327, 2688, 31, 565, 289, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 13400, 29505, 1435, 1216, 6483, 288, 3639, 327, 2688, 31, 565, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
((FreechessConnection) getConn()).sendCommFromPlugin("=ch");
((FreechessConnection) getConn()).sendCommFromPlugin("=ch");
public void loginSucceeded(Connection conn) { ((FreechessConnection) getConn()).sendCommFromPlugin("=ch"); //getConn().sendCommand("inch " + getConn().getUsername()); firstTime = true; // }
50794 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50794/7ad97f640609065fb4cffaab0b5437105af2ce96/ChannelsManager.java/buggy/src/free/jin/channels/ChannelsManager.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 3925, 30500, 12, 1952, 1487, 13, 288, 377, 202, 12443, 9194, 343, 403, 1952, 13, 336, 3543, 1435, 2934, 4661, 12136, 1265, 3773, 2932, 33, 343, 8863, 377, 202, 759, 588, 3543, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3925, 30500, 12, 1952, 1487, 13, 288, 377, 202, 12443, 9194, 343, 403, 1952, 13, 336, 3543, 1435, 2934, 4661, 12136, 1265, 3773, 2932, 33, 343, 8863, 377, 202, 759, 588, 3543, ...
if (distanceFromEdge < MIN_FASTVIEW_SIZE) { distanceFromEdge = MIN_FASTVIEW_SIZE; }
public void widgetSelected(SelectionEvent e) { if (currentPane != null) { Rectangle bounds = clientComposite.getClientArea(); Point location = new Point(e.x, e.y); int distanceFromEdge = Geometry.getDistanceFromEdge(bounds, location, side); if (distanceFromEdge < MIN_FASTVIEW_SIZE) { distanceFromEdge = MIN_FASTVIEW_SIZE; } if (!(side == SWT.TOP || side == SWT.LEFT)) { distanceFromEdge -= SASH_SIZE; } setSize(distanceFromEdge); if (e.detail != SWT.DRAG) { updateFastViewSashBounds();// getPresentation().getControl().moveAbove(null);// currentPane.moveAbove(null); // sash.moveAbove(null); //currentPane.getControl().redraw(); sash.redraw(); } } }
58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/8367ec8d82ef68c8daa2c2966aa8a908fd214f93/FastViewPane.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/FastViewPane.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 3196, 202, 482, 918, 3604, 7416, 12, 6233, 1133, 425, 13, 288, 1082, 202, 430, 261, 2972, 8485, 480, 446, 13, 288, 9506, 202, 19463, 4972, 273, 1004, 9400, 18, 588, 1227, 5484, 5621, 9506, 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, 3196, 202, 482, 918, 3604, 7416, 12, 6233, 1133, 425, 13, 288, 1082, 202, 430, 261, 2972, 8485, 480, 446, 13, 288, 9506, 202, 19463, 4972, 273, 1004, 9400, 18, 588, 1227, 5484, 5621, 9506, 2...
public AbstractOpenWizardWorkbenchAction(IWorkbench workbench, String label, Class[] activatedOnTypes, boolean acceptEmptySelection) { super(workbench, label, null, acceptEmptySelection);
protected AbstractOpenWizardWorkbenchAction() {
public AbstractOpenWizardWorkbenchAction(IWorkbench workbench, String label, Class[] activatedOnTypes, boolean acceptEmptySelection) { super(workbench, label, null, acceptEmptySelection); }
8196 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8196/92877881c60dbe9d268d55e932364742a450a0a8/AbstractOpenWizardWorkbenchAction.java/buggy/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/actions/AbstractOpenWizardWorkbenchAction.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 4115, 3678, 27130, 2421, 22144, 1803, 12, 45, 2421, 22144, 1440, 22144, 16, 514, 1433, 16, 1659, 8526, 14892, 1398, 2016, 16, 1250, 2791, 1921, 6233, 13, 288, 202, 202, 9565, 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, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 4115, 3678, 27130, 2421, 22144, 1803, 12, 45, 2421, 22144, 1440, 22144, 16, 514, 1433, 16, 1659, 8526, 14892, 1398, 2016, 16, 1250, 2791, 1921, 6233, 13, 288, 202, 202, 9565, 12...
throw new NoSuchElementException("This cursor isn't storing BackPointers.");
throw new NoSuchElementException("This cursor isn't storing BackPointers.");
public BackPointer[] getBackPointers(int[] coords) { throw new NoSuchElementException("This cursor isn't storing BackPointers."); }
50397 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50397/dc7b3edc7f85e7b94903a263787fdbfcd26d71e3/PairwiseDP.java/buggy/src/org/biojava/bio/dp/PairwiseDP.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 4297, 4926, 8526, 336, 2711, 27452, 12, 474, 8526, 6074, 13, 288, 202, 12849, 394, 23104, 2932, 2503, 3347, 5177, 1404, 15729, 4297, 27452, 1199, 1769, 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, 0, 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, 4297, 4926, 8526, 336, 2711, 27452, 12, 474, 8526, 6074, 13, 288, 202, 12849, 394, 23104, 2932, 2503, 3347, 5177, 1404, 15729, 4297, 27452, 1199, 1769, 565, 289, 2, -100, -100, -100, ...
} }
} }
private void compute(SIRSplitJoin sj) { // fill in the execution count info for this HashMap[] execCount = SIRScheduler.getExecutionCounts(sj); for (int i=0; i<sj.size(); i++) { // get the steady-state count int[] count = (int[])execCount[1].get(sj.get(i)); if (count==null) { this.child[i] = 0; } else { this.child[i] = count[0]; } } // infer how many times the splitter, joiner runs int[] splitWeights = sj.getSplitter().getWeights(); int[] joinWeights = sj.getJoiner().getWeights(); // infer how many times the splitter, joiner runs // beware of sources in splits int index = -1; boolean nullSplit = false, nullJoin = false; for (int i=0; i<child.length;i++) { if (child[i]!=0 && splitWeights[i]!=0 && joinWeights[i]!=0) { index = i; break; } if (i==child.length-1) { // trying to fuse null split or join -- assume weight // on opposite is okay index = i; if (splitWeights[i]==0) { nullSplit = true; } else { nullJoin = true; } // Utils.fail("Think we're trying to fuse a null split or something--error"); } } if (nullSplit) { this.splitter = 0; } else { this.splitter = child[index] * ((SIRFilter)sj.get(index)).getPopInt() / splitWeights[index]; // make sure we came out even assert this.splitter * splitWeights[index] == this.child[index] * ((SIRFilter)sj.get(index)).getPopInt(); } // now for joiner if (nullJoin) { this.joiner = 0; } else { this.joiner = this.child[index] * ((SIRFilter)sj.get(index)).getPushInt() / joinWeights[index]; // make sure we come out even assert this.joiner * joinWeights[index] == this.child[index] * ((SIRFilter)sj.get(index)).getPushInt(); } }
47772 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47772/03ef03e314c1f2eb8688316cfd664d255ee4592c/FuseSimpleSplit.java/buggy/streams/src/at/dms/kjc/sir/lowering/fusion/FuseSimpleSplit.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 3671, 12, 2320, 54, 5521, 4572, 30252, 13, 288, 202, 565, 368, 3636, 316, 326, 4588, 1056, 1123, 364, 333, 202, 565, 4317, 8526, 1196, 1380, 273, 5705, 54, 11870, 18, 58...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 3671, 12, 2320, 54, 5521, 4572, 30252, 13, 288, 202, 565, 368, 3636, 316, 326, 4588, 1056, 1123, 364, 333, 202, 565, 4317, 8526, 1196, 1380, 273, 5705, 54, 11870, 18, 58...
state = gData.stateStack[gData.stateStackTop]; state.continuation_pc = currentContinuation_pc; state.continuation_op = currentContinuation_op; state.savedBackTrackLast = gData.backTrackLast; state.index = gData.cp; ++gData.stateStackTop;
executeREBytecode(REGlobalData gData, char[] chars, int end) { int pc = 0; byte program[] = gData.regexp.program; int op = program[pc++]; int currentContinuation_op; int currentContinuation_pc; boolean result = false; currentContinuation_pc = 0; currentContinuation_op = REOP_END;if (debug) {System.out.println("Input = \"" + new String(chars) + "\", start at " + gData.cp);} for (;;) {if (debug) {System.out.println("Testing at " + gData.cp + ", op = " + op);} switch (op) { case REOP_EMPTY: result = true; break; case REOP_BOL: if (gData.cp != 0) { if (gData.multiline || ((gData.regexp.flags & JSREG_MULTILINE) != 0)) { if (!isLineTerm(chars[gData.cp - 1])) { result = false; break; } } else { result = false; break; } } result = true; break; case REOP_EOL: if (gData.cp != end) { if (gData.multiline || ((gData.regexp.flags & JSREG_MULTILINE) != 0)) { if (!isLineTerm(chars[gData.cp])) { result = false; break; } } else { result = false; break; } } result = true; break; case REOP_WBDRY: result = ((gData.cp == 0 || !isWord(chars[gData.cp - 1])) ^ !((gData.cp < end) && isWord(chars[gData.cp]))); break; case REOP_WNONBDRY: result = ((gData.cp == 0 || !isWord(chars[gData.cp - 1])) ^ ((gData.cp < end) && isWord(chars[gData.cp]))); break; case REOP_DOT: result = (gData.cp != end && !isLineTerm(chars[gData.cp])); if (result) { gData.cp++; } break; case REOP_DIGIT: result = (gData.cp != end && isDigit(chars[gData.cp])); if (result) { gData.cp++; } break; case REOP_NONDIGIT: result = (gData.cp != end && !isDigit(chars[gData.cp])); if (result) { gData.cp++; } break; case REOP_SPACE: result = (gData.cp != end && isREWhiteSpace(chars[gData.cp])); if (result) { gData.cp++; } break; case REOP_NONSPACE: result = (gData.cp != end && !isREWhiteSpace(chars[gData.cp])); if (result) { gData.cp++; } break; case REOP_ALNUM: result = (gData.cp != end && isWord(chars[gData.cp])); if (result) { gData.cp++; } break; case REOP_NONALNUM: result = (gData.cp != end && !isWord(chars[gData.cp])); if (result) { gData.cp++; } break; case REOP_FLAT: { int offset = GET_ARG(program, pc); pc += ARG_LEN; int length = GET_ARG(program, pc); pc += ARG_LEN; result = flatNMatcher(gData, offset, length, chars, end); } break; case REOP_FLATi: { int offset = GET_ARG(program, pc); pc += ARG_LEN; int length = GET_ARG(program, pc); pc += ARG_LEN; result = flatNIMatcher(gData, offset, length, chars, end); } break; case REOP_FLAT1: { char matchCh = (char)(program[pc++] & 0xFF); result = (gData.cp != end && chars[gData.cp] == matchCh); if (result) { gData.cp++; } } break; case REOP_FLAT1i: { char matchCh = (char)(program[pc++] & 0xFF); result = (gData.cp != end && upcase(chars[gData.cp]) == upcase(matchCh)); if (result) { gData.cp++; } } break; case REOP_UCFLAT1: { char matchCh = (char)GET_ARG(program, pc); pc += ARG_LEN; result = (gData.cp != end && chars[gData.cp] == matchCh); if (result) { gData.cp++; } } break; case REOP_UCFLAT1i: { char matchCh = (char)GET_ARG(program, pc); pc += ARG_LEN; result = (gData.cp != end && upcase(chars[gData.cp]) == upcase(matchCh)); if (result) { gData.cp++; } } break; case REOP_ALT: { int nextpc; byte nextop; REProgState state; state = gData.stateStack[gData.stateStackTop]; state.continuation_pc = currentContinuation_pc; state.continuation_op = currentContinuation_op; ++gData.stateStackTop; nextpc = pc + GET_OFFSET(program, pc); nextop = program[nextpc++]; pushBackTrackState(gData, nextop, nextpc); pc += ARG_LEN; op = program[pc++]; } continue; case REOP_JUMP: { int offset; REProgState state; --gData.stateStackTop; state = gData.stateStack[gData.stateStackTop]; currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; offset = GET_OFFSET(program, pc); pc += offset; op = program[pc++]; } continue; case REOP_LPAREN: { int parenIndex = GET_ARG(program, pc); pc += ARG_LEN; gData.set_parens(parenIndex, gData.cp, 0); op = program[pc++]; } continue; case REOP_RPAREN: { int cap_index; int parenIndex = GET_ARG(program, pc); pc += ARG_LEN; cap_index = gData.parens_index(parenIndex); gData.set_parens(parenIndex, cap_index, gData.cp - cap_index); if (parenIndex > gData.lastParen) gData.lastParen = parenIndex; op = program[pc++]; } continue; case REOP_BACKREF: { int parenIndex = GET_ARG(program, pc); pc += ARG_LEN; result = backrefMatcher(gData, parenIndex, chars, end); } break; case REOP_CLASS: { int index = GET_ARG(program, pc); pc += ARG_LEN; if (gData.cp != end) { if (classMatcher(gData, gData.regexp.classList[index], chars[gData.cp])) { gData.cp++; result = true; break; } } result = false; } break; case REOP_ASSERT: case REOP_ASSERT_NOT: { byte testOp; REProgState state; if (op == REOP_ASSERT) { testOp = REOP_ASSERTTEST; } else { testOp = REOP_ASSERTNOTTEST; } state = gData.stateStack[gData.stateStackTop]; state.continuation_pc = currentContinuation_pc; state.continuation_op = currentContinuation_op; state.savedBackTrackLast = gData.backTrackLast; state.index = gData.cp; ++gData.stateStackTop; pushBackTrackState(gData, testOp, pc + GET_OFFSET(program, pc)); pc += ARG_LEN; op = program[pc++]; } continue; case REOP_ASSERTTEST: case REOP_ASSERTNOTTEST: { REProgState state; --gData.stateStackTop; state = gData.stateStack[gData.stateStackTop]; gData.cp = state.index; gData.backTrackLast = state.savedBackTrackLast; currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; if (result) { if (op == REOP_ASSERTTEST) { result = true; } else { result = false; } } else { if (op == REOP_ASSERTTEST) { // Do nothing } else { result = true; } } } break; case REOP_STAR: case REOP_PLUS: case REOP_OPT: case REOP_QUANT: case REOP_MINIMALSTAR: case REOP_MINIMALPLUS: case REOP_MINIMALOPT: case REOP_MINIMALQUANT: { REProgState state; int min, max; boolean greedy = false; switch (op) { case REOP_STAR: greedy = true; // fallthrough case REOP_MINIMALSTAR: min = 0; max = -1; break; case REOP_PLUS: greedy = true; // fallthrough case REOP_MINIMALPLUS: min = 1; max = -1; break; case REOP_OPT: greedy = true; // fallthrough case REOP_MINIMALOPT: min = 0; max = 1; break; case REOP_QUANT: greedy = true; // fallthrough case REOP_MINIMALQUANT: min = GET_ARG(program, pc); pc += ARG_LEN; max = GET_ARG(program, pc); pc += ARG_LEN; break; default: throw Kit.codeBug(); } state = gData.stateStack[gData.stateStackTop]; state.min = min; state.max = max; state.index = gData.cp; state.continuation_pc = currentContinuation_pc; state.continuation_op = currentContinuation_op; ++gData.stateStackTop; if (greedy) { currentContinuation_op = REOP_REPEAT; currentContinuation_pc = pc; pushBackTrackState(gData, REOP_REPEAT, pc); /* Step over <parencount>, <parenindex> & <next> */ pc += 3 * ARG_LEN; op = program[pc++]; } else { if (min != 0) { currentContinuation_op = REOP_MINIMALREPEAT; currentContinuation_pc = pc; /* <parencount> <parenindex> & <next> */ pc += 3 * ARG_LEN; op = program[pc++]; } else { pushBackTrackState(gData, REOP_MINIMALREPEAT, pc); --gData.stateStackTop; pc += 2 * ARG_LEN; // <parencount> & <parenindex> pc = pc + GET_OFFSET(program, pc); op = program[pc++]; } } } continue; case REOP_ENDCHILD: pc = currentContinuation_pc; op = currentContinuation_op; continue; case REOP_REPEAT: { REProgState state; --gData.stateStackTop; state = gData.stateStack[gData.stateStackTop]; if (!result) { // // There's been a failure, see if we have enough // children. // if (state.min == 0) result = true; currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; pc += 2 * ARG_LEN; /* <parencount> & <parenindex> */ pc = pc + GET_OFFSET(program, pc); break; } else { if (state.min == 0 && gData.cp == state.index) { // matched an empty string, that'll get us nowhere result = false; currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; pc += 2 * ARG_LEN; pc = pc + GET_OFFSET(program, pc); break; } if (state.min != 0) state.min--; if (state.max != -1) state.max--; if (state.max == 0) { result = true; currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; pc += 2 * ARG_LEN; pc = pc + GET_OFFSET(program, pc); break; } state.index = gData.cp; ++gData.stateStackTop; currentContinuation_op = REOP_REPEAT; currentContinuation_pc = pc; pushBackTrackState(gData, REOP_REPEAT, pc); int parenCount = GET_ARG(program, pc); pc += ARG_LEN; int parenIndex = GET_ARG(program, pc); pc += 2 * ARG_LEN; op = program[pc++]; for (int k = 0; k < parenCount; k++) { gData.set_parens(parenIndex + k, -1, 0); } } } continue; case REOP_MINIMALREPEAT: { REProgState state; --gData.stateStackTop; state = gData.stateStack[gData.stateStackTop]; if (!result) { // // Non-greedy failure - try to consume another child. // if (state.max == -1 || state.max > 0) { state.index = gData.cp; currentContinuation_op = REOP_MINIMALREPEAT; currentContinuation_pc = pc; int parenCount = GET_ARG(program, pc); pc += ARG_LEN; int parenIndex = GET_ARG(program, pc); pc += 2 * ARG_LEN; for (int k = 0; k < parenCount; k++) { gData.set_parens(parenIndex + k, -1, 0); } ++gData.stateStackTop; op = program[pc++]; continue; } else { // Don't need to adjust pc since we're going to pop. currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; break; } } else { if (state.min == 0 && gData.cp == state.index) { // Matched an empty string, that'll get us nowhere. result = false; currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; break; } if (state.min != 0) state.min--; if (state.max != -1) state.max--; if (state.min != 0) { currentContinuation_op = REOP_MINIMALREPEAT; currentContinuation_pc = pc; int parenCount = GET_ARG(program, pc); pc += ARG_LEN; int parenIndex = GET_ARG(program, pc); pc += 2 * ARG_LEN; for (int k = 0; k < parenCount; k++) { gData.set_parens(parenIndex + k, -1, 0); } state.index = gData.cp; ++gData.stateStackTop; op = program[pc++]; } else { currentContinuation_pc = state.continuation_pc; currentContinuation_op = state.continuation_op; state.index = gData.cp; ++gData.stateStackTop; pushBackTrackState(gData, REOP_MINIMALREPEAT, pc); --gData.stateStackTop; pc += 2 * ARG_LEN; pc = pc + GET_OFFSET(program, pc); op = program[pc++]; } continue; } } case REOP_END: return true; default: throw Kit.codeBug(); } /* * If the match failed and there's a backtrack option, take it. * Otherwise this is a complete and utter failure. */ if (!result) { REBackTrackData backTrackData = gData.backTrackLast; if (backTrackData != null) { gData.backTrackLast = backTrackData.previous; gData.lastParen = backTrackData.lastParen; // XXX: If backTrackData will no longer be used, then // there is no need to clone backTrackData.parens if (backTrackData.parens != null) { gData.parens = (long[])backTrackData.parens.clone(); } gData.cp = backTrackData.cp; for (int k = 0; k < backTrackData.precedingStateTop; k++) gData.stateStack[k] = backTrackData.precedingState[k]; gData.stateStackTop = backTrackData.precedingStateTop + 1; gData.stateStack[gData.stateStackTop - 1] = backTrackData.currentState; currentContinuation_op = gData.stateStack[gData.stateStackTop - 1].continuation_op; currentContinuation_pc = gData.stateStack[gData.stateStackTop - 1].continuation_pc; pc = backTrackData.continuation_pc; op = backTrackData.continuation_op; continue; } else return false; } /* * Continue with the expression. If this the end of the child, use * the current continuation. */ op = program[pc++]; if (op == REOP_ENDCHILD) { pc = currentContinuation_pc; op = currentContinuation_op; } } }
54155 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54155/bfc17d4124cf8110e97525c9b240855202f5ac65/NativeRegExp.java/buggy/js/rhino/src/org/mozilla/javascript/regexp/NativeRegExp.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1836, 862, 858, 16651, 12, 862, 5160, 751, 314, 751, 16, 1149, 8526, 5230, 16, 509, 679, 13, 565, 288, 3639, 509, 6125, 273, 374, 31, 3639, 1160, 5402, 8526, 273, 314, 751, 18, 17745, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1836, 862, 858, 16651, 12, 862, 5160, 751, 314, 751, 16, 1149, 8526, 5230, 16, 509, 679, 13, 565, 288, 3639, 509, 6125, 273, 374, 31, 3639, 1160, 5402, 8526, 273, 314, 751, 18, 17745, ...
public Box layout( Context c, Element parent, Node text ) {
public Box layout(Context c, Element parent, Node text) {
public Box layout( Context c, Element parent, Node text ) { this.parent = parent; this.text = text; //Box box = new AnonymousBlockBox(text); Box box = super.layout( c, parent ); //u.p("AnonymousBoxLayout.layout: returning: " + box); return box; }
52947 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52947/a02f21737e5cac245dc17710370c9c1eda2116b3/AnonymousBoxLayout.java/buggy/src/java/org/xhtmlrenderer/layout/AnonymousBoxLayout.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 8549, 3511, 12, 1042, 276, 16, 3010, 982, 16, 2029, 977, 13, 288, 3639, 333, 18, 2938, 273, 982, 31, 3639, 333, 18, 955, 273, 977, 31, 3639, 368, 3514, 3919, 273, 394, 29775, 17...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 8549, 3511, 12, 1042, 276, 16, 3010, 982, 16, 2029, 977, 13, 288, 3639, 333, 18, 2938, 273, 982, 31, 3639, 333, 18, 955, 273, 977, 31, 3639, 368, 3514, 3919, 273, 394, 29775, 17...
tmp_state=msg_listener.getState(); } catch(Throwable t) {
tmp_state = msg_listener.getState(); } catch (Throwable t) {
public void passUp(Event evt) { byte[] tmp_state=null; switch(evt.getType()) { case Event.MSG: if(msg_listener != null) msg_listener.receive((Message)evt.getArg()); break; case Event.GET_APPLSTATE: // reply with GET_APPLSTATE_OK if(msg_listener != null) { try { tmp_state=msg_listener.getState(); } catch(Throwable t) { log.error("failed getting state from message listener (" + msg_listener + ")", t); } } channel.returnState(tmp_state); break; case Event.GET_STATE_OK: if(msg_listener != null) { try { msg_listener.setState((byte[])evt.getArg()); } catch(ClassCastException cast_ex) { if(log.isErrorEnabled()) log.error("received SetStateEvent, but argument " + evt.getArg() + " is not serializable. Discarding message."); } } break; case Event.VIEW_CHANGE: View v=(View)evt.getArg(); Vector new_mbrs=v.getMembers(); if(new_mbrs != null) { members.removeAllElements(); for(int i=0; i < new_mbrs.size(); i++) members.addElement(new_mbrs.elementAt(i)); } if(membership_listener != null) membership_listener.viewAccepted(v); break;//// case Event.SET_LOCAL_ADDRESS:// local_addr=(Address)evt.getArg();// break; case Event.SUSPECT: if(membership_listener != null) membership_listener.suspect((Address)evt.getArg()); break; case Event.BLOCK: if(membership_listener != null) membership_listener.block(); break; } }
48949 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48949/9b133caccdd70cd06c1674ee2a42e75071fdc287/MessageDispatcher.java/clean/src/org/jgroups/blocks/MessageDispatcher.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 540, 1071, 918, 1342, 1211, 12, 1133, 6324, 13, 288, 5411, 1160, 8526, 1853, 67, 2019, 33, 2011, 31, 5411, 1620, 12, 73, 11734, 18, 588, 559, 10756, 288, 7734, 648, 2587, 18, 11210, 30, 1079...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1342, 1211, 12, 1133, 6324, 13, 288, 5411, 1160, 8526, 1853, 67, 2019, 33, 2011, 31, 5411, 1620, 12, 73, 11734, 18, 588, 559, 10756, 288, 7734, 648, 2587, 18, 11210, 30, 1079...
return name + " " + (item != null ? item.toString() : "");
return name;
public String toString() { return name + " " + (item != null ? item.toString() : ""); }
49846 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49846/09de3b801384c87038866559a281bbef074f8374/Target.java/buggy/java/de/dfki/lt/mary/unitselection/Target.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 514, 1762, 1435, 565, 288, 3639, 327, 508, 31, 565, 289, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 514, 1762, 1435, 565, 288, 3639, 327, 508, 31, 565, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
bcfgSelectAllButton.setText(AspectJUIPlugin.getResourceString("newResourcesWizard.selectAllConfigurations"));
bcfgSelectAllButton.setText(UIMessages.newResourcesWizard_selectAllConfigurations);
public void createControl(Composite composite) { // Initialize the top level container for the controls topLevel = new Composite(composite, SWT.NONE); topLevel.setLayout(new GridLayout()); // Inform the user what they have to do via a label Label l = new Label(topLevel, SWT.NONE); l.setText(AspectJUIPlugin.getResourceString("newResourcesWizard.instructions")); // Create a two column grid, left hand column is for resources, right hand column is for build config files GridLayout glayout = new GridLayout(); Group group = new Group(topLevel, SWT.SHADOW_NONE); group.setLayoutData(new GridData(GridData.FILL_BOTH)); glayout.numColumns = 2; group.setLayout(glayout); // Calculate the appropriate path to trim off the full resource paths, so that // they present nicely in the lists. IPath trimPath = AspectJPlugin.getDefault().getCurrentProject().getLocation(); trimPath = trimPath.removeLastSegments(1); String trimPathString = new String(trimPath.toOSString() + File.separator); // Populate the left hand group, a list and two buttons (selectAll/deselectAll) Group resGroup = new Group(group, SWT.NONE); GridLayout resLayout = new GridLayout(); resLayout.numColumns = 1; resGroup.setLayout(resLayout); resGroup.setLayoutData(new GridData(GridData.FILL_BOTH)); // The list of resources is presented as a checkbox tree newResourcesTree = new Tree(resGroup, SWT.CHECK | SWT.MULTI); newResourcesTree.setLayoutData(new GridData(GridData.FILL_BOTH)); ListIterator resIterator = newResourcesList.listIterator(); while (resIterator.hasNext()) { IResource iresource = (IResource) resIterator.next(); String absolutePath = iresource.getLocation().toOSString(); TreeItem titem = new TreeItem(newResourcesTree, SWT.NULL); titem.setText(absolutePath.substring(trimPathString.length())); titem.setData(iresource); // Store the iresource in the tree node for use later titem.setChecked(true); // Select all nodes by default } // Populate the right hand group, a list and two buttons (selectAll/deselectAll) Group bcfgGroup = new Group(group, SWT.NONE); GridLayout bcfgLayout = new GridLayout(); bcfgLayout.numColumns = 1; bcfgGroup.setLayout(bcfgLayout); bcfgGroup.setLayoutData(new GridData(GridData.FILL_BOTH)); // The list of resources is presented as a checkbox tree buildConfigFilesTree = new Tree(bcfgGroup, SWT.CHECK | SWT.MULTI); buildConfigFilesTree.setLayoutData(new GridData(GridData.FILL_BOTH)); ListIterator iterator = buildConfigFiles.listIterator(); while (iterator.hasNext()) { IResource iresource = (IResource) iterator.next(); String absolutePath = iresource.getLocation().toOSString(); TreeItem titem = new TreeItem(buildConfigFilesTree, SWT.NULL); titem.setText(absolutePath.substring(trimPathString.length())); titem.setData(iresource); titem.setChecked(true); } // Add the four buttons Button resSelectAllButton = new Button(group, SWT.NONE); resSelectAllButton.setText(AspectJUIPlugin.getResourceString("newResourcesWizard.selectAllResources")); resSelectAllButton.setLayoutData( new GridData(GridData.HORIZONTAL_ALIGN_CENTER)); resSelectAllButton.addSelectionListener(this); Button bcfgSelectAllButton = new Button(group, SWT.NONE); bcfgSelectAllButton.setText(AspectJUIPlugin.getResourceString("newResourcesWizard.selectAllConfigurations")); bcfgSelectAllButton.setLayoutData( new GridData(GridData.HORIZONTAL_ALIGN_CENTER)); bcfgSelectAllButton.addSelectionListener(this); Button resSelectNoneButton = new Button(group, SWT.NONE); resSelectNoneButton.setText(AspectJUIPlugin.getResourceString("newResourcesWizard.deselectAllResources")); resSelectNoneButton.setLayoutData( new GridData(GridData.HORIZONTAL_ALIGN_CENTER)); resSelectNoneButton.addSelectionListener(this); Button bcfgSelectNoneButton = new Button(group, SWT.NONE); bcfgSelectNoneButton.setText(AspectJUIPlugin.getResourceString("newResourcesWizard.deselectAllConfigurations")); bcfgSelectNoneButton.setLayoutData( new GridData(GridData.HORIZONTAL_ALIGN_CENTER)); bcfgSelectNoneButton.addSelectionListener(this); setErrorMessage(null); setMessage(null); setControl(topLevel); setPageComplete(true); }
13558 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13558/db7704a16405007af064b9eaf64639d601bcfc7c/ResourceAddedPage.java/buggy/org.eclipse.ajdt.ui/src/org/eclipse/ajdt/internal/ui/wizards/ResourceAddedPage.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 752, 3367, 12, 9400, 9635, 13, 288, 202, 202, 759, 9190, 326, 1760, 1801, 1478, 364, 326, 11022, 202, 202, 3669, 2355, 273, 394, 14728, 12, 27676, 16, 348, 8588, 18, 9826...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 9635, 13, 288, 202, 202, 759, 9190, 326, 1760, 1801, 1478, 364, 326, 11022, 202, 202, 3669, 2355, 273, 394, 14728, 12, 27676, 16, 348, 8588, 18, 9826...
String message = (String) getCommandLine().getArgumentValue(SVNArgument.MESSAGE); String root = PathUtil.getCommonRoot(new String[] {destPath, srcPath});
String message = (String) getCommandLine().getArgumentValue(SVNArgument.MESSAGE); String root = PathUtil.getCommonRoot(new String[] { destPath, srcPath });
private void runRemote(PrintStream out) throws SVNException { String srcPath = getCommandLine().getURL(0); String destPath = getCommandLine().getURL(1); String message = (String) getCommandLine().getArgumentValue(SVNArgument.MESSAGE); String root = PathUtil.getCommonRoot(new String[] {destPath, srcPath}); SVNRepository repository = createRepository(root); long revNumber = -1; String revStr = (String) getCommandLine().getArgumentValue(SVNArgument.REVISION); if (revStr != null) { try { revNumber = Long.parseLong(revStr); } catch (NumberFormatException e) { revNumber = -1; } } if (revNumber < 0) { revNumber = repository.getLatestRevision(); } String deletePath = srcPath.substring(root.length()); destPath = destPath.substring(root.length()); deletePath = PathUtil.removeLeadingSlash(deletePath); destPath = PathUtil.removeLeadingSlash(destPath); destPath = PathUtil.decode(destPath); deletePath = PathUtil.decode(deletePath); ISVNEditor editor = repository.getCommitEditor(message, null); try { editor.openRoot(-1); DebugLog.log("adding: " + destPath + " from " + deletePath); editor.addDir(destPath, deletePath, revNumber); editor.closeDir(); DebugLog.log("deleting: " + deletePath + " at " + revNumber); editor.deleteEntry(deletePath, revNumber); editor.closeDir(); SVNCommitInfo info = editor.closeEdit(); out.println(); out.println("Committed revision " + info.getNewRevision() + "."); } catch (SVNException e) { if (editor != null) { try { editor.abortEdit(); } catch (SVNException inner) {} } throw e; } }
2776 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2776/361abb3f2b60edf9d7118d2818fa082a63ad66ca/MoveCommand.java/buggy/javasvn/src/org/tmatesoft/svn/cli/command/MoveCommand.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 1086, 5169, 12, 5108, 1228, 596, 13, 1216, 29537, 50, 503, 288, 3639, 514, 19497, 273, 12856, 1670, 7675, 588, 1785, 12, 20, 1769, 3639, 514, 22459, 273, 12856, 1670, 7675...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 1086, 5169, 12, 5108, 1228, 596, 13, 1216, 29537, 50, 503, 288, 3639, 514, 19497, 273, 12856, 1670, 7675, 588, 1785, 12, 20, 1769, 3639, 514, 22459, 273, 12856, 1670, 7675...
return aPolygon;
return aPolygon;
public java.awt.Polygon convertPolygon(SVGPolygonElementImpl svgpl, int x, int y) { java.awt.Polygon aPolygon = new java.awt.Polygon(); Vector points = svgpl.points; PathPoint p; for (int i = 0; i < points.size(); i++) { p = (PathPoint) points.elementAt(i); aPolygon.addPoint((int) (x / 1000f + p.x), pageHeight - (int) (y / 1000f - p.y)); } return aPolygon; }
5268 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5268/e52ac744cd6cb7bf0ce3a82e6530680ed5180cbc/AWTRenderer.java/clean/src/org/apache/fop/render/awt/AWTRenderer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 2252, 18, 2219, 88, 18, 11787, 1765, 11787, 12, 26531, 11787, 1046, 2828, 9804, 412, 16, 509, 619, 16, 509, 677, 13, 288, 565, 2252, 18, 2219, 88, 18, 11787, 279, 11787, 273, 394,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2252, 18, 2219, 88, 18, 11787, 1765, 11787, 12, 26531, 11787, 1046, 2828, 9804, 412, 16, 509, 619, 16, 509, 677, 13, 288, 565, 2252, 18, 2219, 88, 18, 11787, 279, 11787, 273, 394,...
int end;
protected void handlePPDirective(int pos) throws EndOfFileException { char[] buffer = bufferStack[bufferStackPos]; int limit = bufferLimit[bufferStackPos]; int startingLineNumber = getLineNumber(pos); skipOverWhiteSpace(); if (isLimitReached()) handleCompletionOnPreprocessorDirective("#"); //$NON-NLS-1$ // find the directive int start = ++bufferPos[bufferStackPos]; // if new line or end of buffer, we're done if (start >= limit || buffer[start] == '\n') return; boolean problem = false; char c = buffer[start]; if ((c >= 'a' && c <= 'z')) { while (++bufferPos[bufferStackPos] < limit) { c = buffer[bufferPos[bufferStackPos]]; if ((c >= 'a' && c <= 'z') || c == '_') continue; break; } --bufferPos[bufferStackPos]; int len = bufferPos[bufferStackPos] - start + 1; if (isLimitReached()) handleCompletionOnPreprocessorDirective(new String(buffer, pos, len + 1)); int type = ppKeywords.get(buffer, start, len); if (type != ppKeywords.undefined) { switch (type) { case ppInclude: handlePPInclude(pos, false, startingLineNumber); return; case ppInclude_next: handlePPInclude(pos, true, startingLineNumber); return; case ppDefine: handlePPDefine(pos, startingLineNumber); return; case ppUndef: handlePPUndef(pos); return; case ppIfdef: handlePPIfdef(pos, true); return; case ppIfndef: handlePPIfdef(pos, false); return; case ppIf: start = bufferPos[bufferStackPos] + 1; skipToNewLine(); len = bufferPos[bufferStackPos] - start; if (isLimitReached()) handleCompletionOnExpression(CharArrayUtils.extract( buffer, start, len)); branchState(BRANCH_IF); if (expressionEvaluator.evaluate(buffer, start, len, definitions, getLineNumber(bufferPos[bufferStackPos]), getCurrentFilename()) == 0) { processIf(pos, bufferPos[bufferStackPos], false); skipOverConditionalCode(true); if (isLimitReached()) handleInvalidCompletion(); } else { processIf(pos, bufferPos[bufferStackPos], true); } return; case ppElse: case ppElif: // Condition must have been true, skip over the rest if (branchState(type == ppElse ? BRANCH_ELSE : BRANCH_ELIF)) { if (type == ppElse) processElse(pos, bufferPos[bufferStackPos] + 1, false); else processElsif(pos, bufferPos[bufferStackPos], false); skipToNewLine(); skipOverConditionalCode(false); } else { handleProblem( IProblem.PREPROCESSOR_UNBALANCE_CONDITION, start, ppKeywords.findKey(buffer, start, len)); skipToNewLine(); } if (isLimitReached()) handleInvalidCompletion(); return; case ppError: skipOverWhiteSpace(); start = bufferPos[bufferStackPos] + 1; skipToNewLine(); if (bufferPos[bufferStackPos] - 1 > 0 && buffer[bufferPos[bufferStackPos] - 1] == '\r') len = bufferPos[bufferStackPos] - start - 1; else len = bufferPos[bufferStackPos] - start; handleProblem(IProblem.PREPROCESSOR_POUND_ERROR, start, CharArrayUtils.extract(buffer, start, len)); processError(pos, pos + len); break; case ppEndif: if (!branchState(BRANCH_END)) handleProblem( IProblem.PREPROCESSOR_UNBALANCE_CONDITION, start, ppKeywords.findKey(buffer, start, len)); processEndif(pos, bufferPos[bufferStackPos] + 1); break; case ppPragma: skipToNewLine(); processPragma(pos, bufferPos[bufferStackPos]); break; default: problem = true; break; } } } else problem = true; if (problem) handleProblem(IProblem.PREPROCESSOR_INVALID_DIRECTIVE, start, null); // don't know, chew up to the end of line // includes endif which is immatereal at this point skipToNewLine(); }
54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/fdabd9645c02460b6cbe435e46247c1b6cd0db21/BaseScanner.java/buggy/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/parser/scanner2/BaseScanner.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 509, 679, 31, 225, 509, 679, 31, 225, 509, 679, 31, 225, 509, 679, 31, 4750, 509, 679, 31, 918, 509, 679, 31, 1640, 6584, 13307, 12, 474, 509, 679, 31, 949, 13, 509, 679, 31, 1216, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 509, 679, 31, 225, 509, 679, 31, 225, 509, 679, 31, 225, 509, 679, 31, 4750, 509, 679, 31, 918, 509, 679, 31, 1640, 6584, 13307, 12, 474, 509, 679, 31, 949, 13, 509, 679, 31, 1216, ...
File file = new File("resources/adventureData/saves/" + gameName + "." + target.channame + "." + loadSlot);
File file = new File("resources/adventureData/saves"); File[] files = file.listFiles(); for (int i = 0; i < files.length; i++) { String[] parts = files[i].getName().split("\\."); if (parts[0].equals(gameName)) if (parts[1].equals(target.channame)) if (parts[3].equals(Integer.toString(loadSlot))) file = files[i]; }
public byte[] Restore() { File file = new File("resources/adventureData/saves/" + gameName + "." + target.channame + "." + loadSlot); try { FileInputStream fis = new FileInputStream(file); byte[] data = new byte[fis.available()]; fis.read(data); return data; } catch (FileNotFoundException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } return null; }
47073 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47073/51a359526ddf154c11219d8fd2e2deb0f1d3cc7a/Adventure.java/buggy/src/goat/module/Adventure.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 1160, 8526, 11197, 1435, 288, 540, 1387, 585, 273, 394, 1387, 2932, 4683, 19, 361, 616, 594, 751, 19, 87, 6606, 8863, 1387, 8526, 1390, 273, 585, 18, 1098, 2697, 5621, 364, 26...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1160, 8526, 11197, 1435, 288, 540, 1387, 585, 273, 394, 1387, 2932, 4683, 19, 361, 616, 594, 751, 19, 87, 6606, 8863, 1387, 8526, 1390, 273, 585, 18, 1098, 2697, 5621, 364, 26...
for (i=0;i<m_numAttributes;i++) if (feature_set.get(i))
for (i=0;i<m_numAttributes;i++) { if (feature_set.get(i)) {
private double estimateAccuracy(BitSet feature_set, int num_atts) throws Exception { int i; Instances newInstances; int [] fs = new int [num_atts]; double acc = 0.0; double [][] evalArray; double [] instA = new double [num_atts]; int classI = m_theInstances.classIndex(); int index = 0; for (i=0;i<m_numAttributes;i++) if (feature_set.get(i)) fs[index++] = i; // create new hash table m_entries = new Hashtable((int)(m_theInstances.numInstances() * 1.5)); // insert instances into the hash table for (i=0;i<m_numInstances;i++) { Instance inst = m_theInstances.instance(i); for (int j=0;j<fs.length;j++) if (fs[j] == classI) instA[j] = Double.MAX_VALUE; // missing for the class else if (inst.isMissing(fs[j])) instA[j] = Double.MAX_VALUE; else instA[j] = inst.value(fs[j]); insertIntoTable(inst, instA); } if (m_CVFolds == 1) { // calculate leave one out error for (i=0;i<m_numInstances;i++) { Instance inst = m_theInstances.instance(i); for (int j=0;j<fs.length;j++) if (fs[j] == classI) instA[j] = Double.MAX_VALUE; // missing for the class else if (inst.isMissing(fs[j])) instA[j] = Double.MAX_VALUE; else instA[j] = inst.value(fs[j]); double t = classifyInstanceLeaveOneOut(inst, instA); if (m_classIsNominal) { if (t == inst.classValue()) acc+=inst.weight(); } else acc += ((inst.weight() * (t - inst.classValue())) * (inst.weight() * (t - inst.classValue()))); // weight_sum += inst.weight(); } } else { m_theInstances.randomize(m_rr); m_theInstances.stratify(m_CVFolds); // calculate 10 fold cross validation error for (i=0;i<m_CVFolds;i++) { Instances insts = m_theInstances.testCV(m_CVFolds,i); acc += classifyFoldCV(insts, fs); } } if (m_classIsNominal) return (acc / m_theInstances.sumOfWeights()); else return -(Math.sqrt(acc / m_theInstances.sumOfWeights())); }
4773 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4773/9e72041e2204a61830b9cccfa8173a6ed2c39eb5/DecisionTable.java/buggy/weka/classifiers/DecisionTable.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 3238, 1645, 11108, 37, 10988, 12, 5775, 694, 2572, 67, 542, 16, 509, 818, 67, 270, 3428, 13, 565, 1216, 1185, 225, 288, 565, 509, 277, 31, 565, 18357, 394, 5361, 31, 565, 509, 5378, 2...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 3238, 1645, 11108, 37, 10988, 12, 5775, 694, 2572, 67, 542, 16, 509, 818, 67, 270, 3428, 13, 565, 1216, 1185, 225, 288, 565, 509, 277, 31, 565, 18357, 394, 5361, 31, 565, 509, 5378, 2...
indexer.getOutput().addRef(fileNumber, IndexEncoderUtil.encodeEntry( getFullyQualifiedName(binding), IIndexEncodingConstants.DERIVED, ICSearchConstants.DECLARATIONS),
indexer.getOutput().addDerivedDecl(fileNumber, getFullyQualifiedName(binding),
private void addDerivedAndFriendDeclaration(IASTName name, IBinding binding, IASTFileLocation loc, int fileNumber) throws DOMException { ASTNodeProperty prop = name.getPropertyInParent(); if (binding instanceof ICompositeType) { ICompositeType compBinding = (ICompositeType) binding; int compositeKey = compBinding.getKey(); if (compositeKey == ICPPClassType.k_class || compositeKey == ICompositeType.k_struct) { if (prop == ICPPASTBaseSpecifier.NAME) { // base class indexer.getOutput().addRef(fileNumber, IndexEncoderUtil.encodeEntry( getFullyQualifiedName(binding), IIndexEncodingConstants.DERIVED, ICSearchConstants.DECLARATIONS), loc.getNodeOffset(), loc.getNodeLength(), ICIndexStorageConstants.OFFSET); } else if (prop == IASTElaboratedTypeSpecifier.TYPE_NAME) { // friend indexer.getOutput().addRef(fileNumber, IndexEncoderUtil.encodeEntry( getFullyQualifiedName(binding), IIndexEncodingConstants.FRIEND, ICSearchConstants.DECLARATIONS), loc.getNodeOffset(), loc.getNodeLength(), ICIndexStorageConstants.OFFSET); } } } // TODO In case we want to add friend function declarations to index// else if (binding instanceof IFunction) {// IFunction funBinding = (IFunction) binding;// if (prop == IASTFunctionDeclarator.DECLARATOR_NAME) {// IASTFunctionDeclarator fDecl = (IASTFunctionDeclarator) name.getParent();// IASTNode fDeclParent = fDecl.getParent();// if (fDeclParent instanceof IASTSimpleDeclaration) {// IASTSimpleDeclaration sDecl = (IASTSimpleDeclaration) fDeclParent;// IASTDeclSpecifier declSpec = sDecl.getDeclSpecifier();// if (declSpec instanceof ICPPASTSimpleDeclSpecifier) {// ICPPASTSimpleDeclSpecifier fDeclSpec = (ICPPASTSimpleDeclSpecifier) declSpec;// if (fDeclSpec.isFriend()) {// // friend // indexer.getOutput().addRef(fileNumber, IndexEncoderUtil.encodeEntry(// getFullyQualifiedName(binding),// IIndexEncodingConstants.FRIEND,// ICSearchConstants.DECLARATIONS));// }// }// }// }// } }
6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/cf1d5bf0d12520585deffeb5e217fc8ff5159112/CPPGenerateIndexVisitor.java/buggy/core/org.eclipse.cdt.core/index/org/eclipse/cdt/internal/core/index/domsourceindexer/CPPGenerateIndexVisitor.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 527, 21007, 1876, 42, 7522, 6094, 12, 45, 9053, 461, 508, 16, 467, 5250, 5085, 16, 467, 9053, 812, 2735, 1515, 16, 509, 585, 1854, 13, 1216, 4703, 503, 288, 3639, 9183, 907, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 527, 21007, 1876, 42, 7522, 6094, 12, 45, 9053, 461, 508, 16, 467, 5250, 5085, 16, 467, 9053, 812, 2735, 1515, 16, 509, 585, 1854, 13, 1216, 4703, 503, 288, 3639, 9183, 907, ...
rsvc = rs;
this.log = rs.getLog();
public JarHolder( RuntimeServices rs, String urlpath ) { rsvc = rs; this.urlpath=urlpath; init(); rsvc.info(" JarHolder : initialized JAR: " + urlpath ); }
9291 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9291/f4adefb79ccda5d9df1f60719e0ede8f167e4089/JarHolder.java/buggy/src/java/org/apache/velocity/runtime/resource/loader/JarHolder.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 15644, 6064, 12, 2509, 5676, 3597, 16, 514, 880, 803, 262, 565, 288, 3639, 333, 18, 1330, 273, 3597, 18, 588, 1343, 5621, 3639, 333, 18, 718, 803, 33, 718, 803, 31, 3639, 1208, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 15644, 6064, 12, 2509, 5676, 3597, 16, 514, 880, 803, 262, 565, 288, 3639, 333, 18, 1330, 273, 3597, 18, 588, 1343, 5621, 3639, 333, 18, 718, 803, 33, 718, 803, 31, 3639, 1208, ...
public boolean isSet(org.quickfix.field.Symbol field)
public boolean isSet(quickfix.field.Symbol field)
public boolean isSet(org.quickfix.field.Symbol field) { return isSetField(field); }
8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/DerivativeSecurityList.java/clean/src/java/src/quickfix/fix43/DerivativeSecurityList.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 1250, 13532, 12, 19525, 904, 18, 1518, 18, 5335, 652, 13, 225, 288, 327, 13532, 974, 12, 1518, 1769, 289, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 1250, 13532, 12, 19525, 904, 18, 1518, 18, 5335, 652, 13, 225, 288, 327, 13532, 974, 12, 1518, 1769, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
this.iscFractionDigits.setEnabled( enabled
this.spnFractionDigits.setEnabled( enabled
public void setEnabled( boolean enabled ) { this.btnApproximate.setSelection( !getFormatSpecifier( ).isPrecise( ) ); this.btnApproximate.setEnabled( enabled ); this.txtDelimiter.setEnabled( enabled ); this.txtPrefix.setEnabled( enabled ); this.txtSuffix.setEnabled( enabled ); this.btnUseNumerator.setEnabled( enabled && btnApproximate.getSelection( ) ); this.btnUseDenorminator.setEnabled( enabled && btnApproximate.getSelection( ) ); if ( getFormatSpecifier( ).getNumerator( ) > 0 ) { this.btnUseNumerator.setSelection( true ); } else { this.btnUseDenorminator.setSelection( true ); } this.txtNumerator.setEnabled( enabled && btnApproximate.getSelection( ) && btnUseNumerator.getSelection( ) ); this.iscFractionDigits.setEnabled( enabled && btnApproximate.getSelection( ) && btnUseDenorminator.getSelection( ) ); super.setEnabled( enabled ); }
46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/2ad0f26f0a3c46f54066f852dc55a774ff5a1072/FormatSpecifierComposite.java/buggy/chart/org.eclipse.birt.chart.ui.extension/src/org/eclipse/birt/chart/ui/swt/composites/FormatSpecifierComposite.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 3196, 202, 482, 918, 12888, 12, 1250, 3696, 262, 202, 202, 95, 1082, 202, 2211, 18, 11898, 25789, 4988, 18, 542, 6233, 12, 401, 588, 1630, 21416, 12, 262, 18, 291, 1386, 30708, 12, 262, 1127...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 3196, 202, 482, 918, 12888, 12, 1250, 3696, 262, 202, 202, 95, 1082, 202, 2211, 18, 11898, 25789, 4988, 18, 542, 6233, 12, 401, 588, 1630, 21416, 12, 262, 18, 291, 1386, 30708, 12, 262, 1127...
return children;
return this.children;
public AbstractPMDRecord[] getChildren() { return children; }
41673 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/41673/360f19c4b900386d3c70a1e5c4e24aac836e05fd/PackageRecord.java/clean/pmd-eclipse-ui/src/net/sourceforge/pmd/ui/model/PackageRecord.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 4115, 52, 6188, 2115, 8526, 10268, 1435, 288, 3639, 327, 333, 18, 5906, 31, 565, 289, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 4115, 52, 6188, 2115, 8526, 10268, 1435, 288, 3639, 327, 333, 18, 5906, 31, 565, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...
return outerClass;
public static PsiClass getOutermostContainingClass(PsiClass aClass) { PsiClass outerClass = aClass; while (true) { final PsiClass containingClass = (PsiClass) PsiTreeUtil.getParentOfType(outerClass, PsiClass.class); if (containingClass != null) { outerClass = containingClass; } else { break; } } return outerClass; }
12814 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12814/dba8b183fc1b08e7ad664812bfc0c64d1e4abd3c/ClassUtils.java/buggy/plugins/InspectionGadgets/src/com/siyeh/ig/psiutils/ClassUtils.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 760, 453, 7722, 797, 23141, 28055, 24344, 797, 12, 52, 7722, 797, 20148, 13, 288, 3639, 453, 7722, 797, 6390, 797, 273, 20148, 31, 3639, 1323, 261, 3767, 13, 288, 5411, 727, 453, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 453, 7722, 797, 23141, 28055, 24344, 797, 12, 52, 7722, 797, 20148, 13, 288, 3639, 453, 7722, 797, 6390, 797, 273, 20148, 31, 3639, 1323, 261, 3767, 13, 288, 5411, 727, 453, ...
desc.pluginDescriptor = null;
desc.pluginBundle = null;
public void addProvider(IConfigurationElement element) { Descriptor desc = new Descriptor(); desc.element = element; desc.pluginDescriptor = element.getDeclaringExtension() .getDeclaringPluginDescriptor(); desc.id = element.getAttribute(ATT_ID); desc.markerType = element.getAttribute(ATT_MARKER_TYPE); desc.imagePath = element.getAttribute(ATT_ICON); desc.className = element.getAttribute(ATT_PROVIDER_CLASS); if (desc.imagePath != null) { desc.imageDescriptor = getImageDescriptor(desc); } if (desc.className == null) { //Don't need to keep these references. desc.element = null; desc.pluginDescriptor = null; } descriptors.add(desc); }
58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/42db139adc63f580638631e2801cb8a1ed81cfce/MarkerImageProviderRegistry.java/clean/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/registry/MarkerImageProviderRegistry.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 527, 2249, 12, 45, 1750, 1046, 930, 13, 288, 3639, 12823, 3044, 273, 394, 12823, 5621, 3639, 3044, 18, 2956, 273, 930, 31, 3639, 3044, 18, 4094, 3187, 273, 930, 18, 588, 3456...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 527, 2249, 12, 45, 1750, 1046, 930, 13, 288, 3639, 12823, 3044, 273, 394, 12823, 5621, 3639, 3044, 18, 2956, 273, 930, 31, 3639, 3044, 18, 4094, 3187, 273, 930, 18, 588, 3456...
String eval(String expr) {
public String eval(String expr) {
String eval(String expr) { String result = "undefined"; if (expr == null) { return result; } ContextData contextData = currentContextData(); if (contextData == null || frameIndex >= contextData.frameCount()) { return result; } StackFrame frame = contextData.getFrame(frameIndex); if (contextData.eventThreadFlag) { Context cx = Context.getCurrentContext(); result = do_eval(cx, frame, expr); } else { synchronized (monitor) { if (insideInterruptLoop) { evalRequest = expr; evalFrame = frame; monitor.notify(); do { try { monitor.wait(); } catch (InterruptedException exc) { Thread.currentThread().interrupt(); break; } } while (evalRequest != null); result = evalResult; } } } return result; }
7555 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7555/2d4fc75b74d717c754829dde488ff0a7456682cc/Dim.java/buggy/js/rhino/toolsrc/org/mozilla/javascript/tools/debugger/Dim.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 514, 5302, 12, 780, 3065, 13, 565, 288, 3639, 514, 563, 273, 315, 5978, 14432, 3639, 309, 261, 8638, 422, 446, 13, 288, 5411, 327, 563, 31, 3639, 289, 3639, 1772, 751, 819, 751, 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, 514, 5302, 12, 780, 3065, 13, 565, 288, 3639, 514, 563, 273, 315, 5978, 14432, 3639, 309, 261, 8638, 422, 446, 13, 288, 5411, 327, 563, 31, 3639, 289, 3639, 1772, 751, 819, 751, 273, ...
public boolean saveSettings() {//throws IOException { File pr = _projRootSelector.getFileFromField(); if (_projRootSelector.getFileField().getText().equals("")) pr = null; _model.setProjectRoot(pr); File bd = _buildDirSelector.getFileFromField(); if (_buildDirSelector.getFileField().getText().equals("")) bd = null; _model.setBuildDirectory(bd); File wd = _workDirSelector.getFileFromField(); if (_workDirSelector.getFileField().getText().equals("")) wd = null; _model.setWorkingDirectory(wd); File mc = _mainDocumentSelector.getFileFromField(); if (_mainDocumentSelector.getFileField().getText().equals("")) mc = null; _model.setMainClass(mc); Vector<File> extras = _extraClassPathList.getValue(); ClassPathVector cpv = new ClassPathVector(); for (File cf : extras) { cpv.add(cf); } _model.setExtraClassPath(cpv); // _mainFrame.saveProject(); return true; }
11192 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11192/f65c5769a6637710f9e4e352487dd42cf3c9bcd0/ProjectPropertiesFrame.java/clean/drjava/src/edu/rice/cs/drjava/ui/ProjectPropertiesFrame.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 1250, 1923, 2628, 1435, 288, 759, 15069, 1860, 288, 565, 1387, 846, 273, 389, 17995, 2375, 4320, 18, 29925, 1265, 974, 5621, 565, 309, 261, 67, 17995, 2375, 4320, 18, 29925, 974, 76...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1250, 1923, 2628, 1435, 288, 759, 15069, 1860, 288, 565, 1387, 846, 273, 389, 17995, 2375, 4320, 18, 29925, 1265, 974, 5621, 565, 309, 261, 67, 17995, 2375, 4320, 18, 29925, 974, 76...
parse(0, 0, in.length());
allFound = false; foundPixels = false; numParsed = 0; in.mark(2); parse(0, 0, fileLength);
protected void initFile(String id) throws FormatException, IOException { super.initFile(id); in = new RandomAccessFile(id, "r"); offsets = new Vector(); chunkSizes = new Vector(); parse(0, 0, in.length()); numImages = offsets.size(); }
55415 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55415/91859a26506b8a1d312b398da2c3ecd94e02fa60/QTReader.java/buggy/loci/formats/QTReader.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, 2240, 18, 2738, 812, 12, 350, 1769, 565, 316, 273, 394, 8072, 26933, 12, 350, 16, 315, 86, 8863, 565, 8738...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2240, 18, 2738, 812, 12, 350, 1769, 565, 316, 273, 394, 8072, 26933, 12, 350, 16, 315, 86, 8863, 565, 8738...
public boolean isDoubleEscape() { return false; }
public boolean isDoubleEscape() { return false; }
public boolean isDoubleEscape() { return false; }
11192 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11192/e325016b29b8dde8e3ba0908ae34d55edb22c64f/Gap.java/buggy/drjava/src/edu/rice/cs/drjava/model/definitions/reducedmodel/Gap.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 1250, 353, 5265, 8448, 1435, 202, 202, 95, 1082, 202, 2463, 629, 31, 202, 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, ...
[ 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 1250, 353, 5265, 8448, 1435, 202, 202, 95, 1082, 202, 2463, 629, 31, 202, 202, 97, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
kind = 18; jjCheckNAdd(2);
kind = 21; jjCheckNAdd(5);
private final int jjMoveNfa_2(int startState, int curPos){ int[] nextStates; int startsAt = 0; jjnewStateCnt = 3; int i = 1; jjstateSet[0] = startState; int j, kind = 0x7fffffff; for (;;) { if (++jjround == 0x7fffffff) ReInitRounds(); if (curChar < 64) { long l = 1L << curChar; MatchLoop: do { switch(jjstateSet[--i]) { case 0: if ((0x9fffff7affffd9ffL & l) != 0L) { if (kind > 15) kind = 15; jjCheckNAdd(1); } else if ((0x100002600L & l) != 0L) { if (kind > 18) kind = 18; jjCheckNAdd(2); } break; case 1: if ((0xbffffffeffffd9ffL & l) == 0L) break; if (kind > 15) kind = 15; jjCheckNAdd(1); break; case 2: if ((0x100002600L & l) == 0L) break; kind = 18; jjCheckNAdd(2); break; default : break; } } while(i != startsAt); } else if (curChar < 128) { long l = 1L << (curChar & 077); MatchLoop: do { switch(jjstateSet[--i]) { case 0: case 1: if (kind > 15) kind = 15; jjCheckNAdd(1); break; default : break; } } while(i != startsAt); } else { int i2 = (curChar & 0xff) >> 6; long l2 = 1L << (curChar & 077); MatchLoop: do { switch(jjstateSet[--i]) { case 0: case 1: if ((jjbitVec0[i2] & l2) == 0L) break; if (kind > 15) kind = 15; jjCheckNAdd(1); break; default : break; } } while(i != startsAt); } if (kind != 0x7fffffff) { jjmatchedKind = kind; jjmatchedPos = curPos; kind = 0x7fffffff; } ++curPos; if ((i = jjnewStateCnt) == (startsAt = 3 - (jjnewStateCnt = startsAt))) return curPos; try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { return curPos; } }}
1514 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1514/41ab0e084c55ebc2924ca4becd35fb57497b2a50/HTMLParserTokenManager.java/clean/src/demo/org/apache/lucene/demo/html/HTMLParserTokenManager.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 3238, 727, 509, 10684, 7607, 50, 507, 67, 22, 12, 474, 787, 1119, 16, 509, 662, 1616, 15329, 282, 509, 8526, 1024, 7629, 31, 282, 509, 2542, 861, 273, 374, 31, 282, 10684, 2704, 1119, 11750,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 3238, 727, 509, 10684, 7607, 50, 507, 67, 22, 12, 474, 787, 1119, 16, 509, 662, 1616, 15329, 282, 509, 8526, 1024, 7629, 31, 282, 509, 2542, 861, 273, 374, 31, 282, 10684, 2704, 1119, 11750,...
enum = __listeners.getListeners();
en = __listeners.getListeners();
public void fireCommandSent(String command, String message) { Enumeration enum; ProtocolCommandEvent event; ProtocolCommandListener listener; enum = __listeners.getListeners(); event = new ProtocolCommandEvent(__source, command, message); while (enum.hasMoreElements()) { listener = (ProtocolCommandListener)enum.nextElement(); listener.protocolCommandSent(event); }
50121 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50121/5fbc50a66288428e9487304a5609c5607bbb2e1f/ProtocolCommandSupport.java/buggy/src/java/org/apache/commons/net/ProtocolCommandSupport.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 4452, 2189, 7828, 12, 780, 1296, 16, 514, 883, 13, 565, 288, 3639, 13864, 2792, 31, 3639, 4547, 2189, 1133, 871, 31, 3639, 4547, 2189, 2223, 2991, 31, 3639, 570, 273, 1001, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4452, 2189, 7828, 12, 780, 1296, 16, 514, 883, 13, 565, 288, 3639, 13864, 2792, 31, 3639, 4547, 2189, 1133, 871, 31, 3639, 4547, 2189, 2223, 2991, 31, 3639, 570, 273, 1001, 1...
popBuffer[j] = makePopBuffer(filter, num[j], i);
popBuffer[j] = makePopBuffer(filter, peekBufferSize, num[j], i);
private static List makeFilterInfo(List filterList) { // make the result List result = new LinkedList(); // construct a schedule for <filterList> Schedule schedule = getSchedule(filterList); // get the schedules List initSched = schedule.getInitSchedule(); List steadySched = schedule.getSteadySchedule(); // DEBUGGING OUTPUT //SIRScheduler.printSchedule(initSched, "initialization"); //SIRScheduler.printSchedule(steadySched, "steady state"); // for each filter... ListIterator it = filterList.listIterator(); for (int i=0; it.hasNext(); i++) { // the filter SIRFilter filter = (SIRFilter)it.next(); // the peek buffer JVariableDefinition peekBufferVar = new JVariableDefinition(null, at.dms.kjc.Constants.ACC_FINAL, new CArrayType(voidToInt(filter. getInputType()), 1 /* dimension */ ), PEEK_BUFFER_NAME + "_" + i, null); JFieldDeclaration peekBuffer = new JFieldDeclaration(null, peekBufferVar, null, null); // number of executions (num[0] is init, num[1] is steady) int[] num = new int[2]; // for now, guard against empty/incomplete schedules // by assuming a count of zero. Talk to Michal about // have entries of zero-weight in schedule? FIXME. if (initSched.size()>i) { num[0] = ((SchedRepSchedule)initSched.get(i)). getTotalExecutions().intValue(); } else { num[0] = 0; } // do the same for the steady schedule if (steadySched.size()>i) { num[1] = ((SchedRepSchedule)steadySched.get(i)). getTotalExecutions().intValue(); } else { num[1] = 0; } // get ready to make rest of phase-specific info JVariableDefinition popBuffer[] = new JVariableDefinition[2]; JVariableDefinition popCounter[] = new JVariableDefinition[2]; JVariableDefinition pushCounter[] = new JVariableDefinition[2]; JVariableDefinition loopCounter[] = new JVariableDefinition[2]; for (int j=0; j<2; j++) { // the pop buffer popBuffer[j] = makePopBuffer(filter, num[j], i); // the pop counter. popCounter[j] = new JVariableDefinition(null, 0, CStdType.Integer, POP_INDEX_NAME + "_" + j + "_" + i, new JIntLiteral(//filter.getPeekInt() - filter.getPopInt() - 1 /* this is since we're starting at -1 and doing pre-inc instead of post-inc */ )); // the push counter. In the steady state, the initial // value of the push counter is the first slot after // the peek values are restored, which is peek-pop-1 // (-1 since we're pre-incing, not post-incing). In // the inital work function, the push counter starts // at -1 (since we're pre-incing, not post-incing). int pushInit = j==0 ? -1 : filter.getPeekInt() - filter.getPopInt() - 1; pushCounter[j] = new JVariableDefinition(null, 0, CStdType.Integer, PUSH_INDEX_NAME + "_" + j + "_" +i, new JIntLiteral(pushInit)); // the exec counter loopCounter[j] = new JVariableDefinition(null, 0, CStdType.Integer, COUNTER_NAME + "_" + j + "_" +i, null); } // add a filter info to <result> result.add(new FilterInfo(filter, peekBuffer, new PhaseInfo(num[0], popBuffer[0], popCounter[0], pushCounter[0], loopCounter[0]), new PhaseInfo(num[1], popBuffer[1], popCounter[1], pushCounter[1], loopCounter[1]) )); } // return result return result; }
47772 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47772/ecda4670191cbfce0ea3b7ff25182a529c06cc3d/FusePipe.java/clean/streams/src/at/dms/kjc/sir/lowering/fusion/FusePipe.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 760, 987, 1221, 1586, 966, 12, 682, 1034, 682, 13, 288, 202, 759, 1221, 326, 563, 202, 682, 563, 273, 394, 10688, 5621, 202, 759, 4872, 279, 4788, 364, 411, 2188, 682, 34, 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, 377, 3238, 760, 987, 1221, 1586, 966, 12, 682, 1034, 682, 13, 288, 202, 759, 1221, 326, 563, 202, 682, 563, 273, 394, 10688, 5621, 202, 759, 4872, 279, 4788, 364, 411, 2188, 682, 34, 202, ...
} catch (SAXException e) { throw new TransletException(e); }
if (_outputType == HTML) if (elementName.toLowerCase().equals("head")) _headTagOpen = true;
public void startElement(String elementName) throws TransletException { // bug fix # 1499, GTM. if (_outputType == TEXT) return; try { // Close any open start tag if (_startTagOpen) { closeStartTag(); } else if (_cdataTagOpen) { characters(ENDCDATA); _cdataTagOpen = false; } // If we don't know the output type yet we need to examine // the very first element to see if it is "html". if (_outputType == UNKNOWN) { if (elementName.toLowerCase().equals("html")) setTypeInternal(HTML); else setTypeInternal(XML); } _depth++; _elementName = elementName; _attributes.clear(); _startTagOpen = true; _qnameStack.push(elementName); // Insert <META> tag directly after <HEAD> element in HTML doc if (_outputType == HTML) { if (elementName.toLowerCase().equals("head")) { _headTagOpen = true; } } } catch (SAXException e) { throw new TransletException(e); } }
46591 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46591/5812ba64ef7e43ebdaca65f1965e5b7ea57428d1/TextOutput.java/clean/src/org/apache/xalan/xsltc/runtime/TextOutput.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 13591, 12, 780, 14453, 13, 202, 15069, 2604, 1810, 503, 288, 202, 759, 7934, 2917, 468, 5045, 2733, 16, 19688, 49, 18, 202, 430, 261, 67, 2844, 559, 422, 9204, 13, 327, 31, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 13591, 12, 780, 14453, 13, 202, 15069, 2604, 1810, 503, 288, 202, 759, 7934, 2917, 468, 5045, 2733, 16, 19688, 49, 18, 202, 430, 261, 67, 2844, 559, 422, 9204, 13, 327, 31, ...
getImpl().setOption(SocketOptions.SO_OOBINLINE, new Boolean(on));
getImpl().setOption(SocketOptions.SO_OOBINLINE, Boolean.valueOf(on));
public void setOOBInline (boolean on) throws SocketException { if (isClosed()) throw new SocketException("socket is closed"); getImpl().setOption(SocketOptions.SO_OOBINLINE, new Boolean(on)); }
13625 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13625/3e38401205b9ce29b86b1a8606095adabd35b585/Socket.java/buggy/libjava/java/net/Socket.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 918, 444, 51, 5704, 10870, 261, 6494, 603, 13, 1216, 8758, 503, 225, 288, 565, 309, 261, 291, 7395, 10756, 1377, 604, 394, 8758, 503, 2932, 7814, 353, 4375, 8863, 3639, 336, 2828, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 444, 51, 5704, 10870, 261, 6494, 603, 13, 1216, 8758, 503, 225, 288, 565, 309, 261, 291, 7395, 10756, 1377, 604, 394, 8758, 503, 2932, 7814, 353, 4375, 8863, 3639, 336, 2828, ...
int row = _table.rowAtPoint(e.getPoint()); _table.setRowSelectionInterval(row, row);
_lastRow = _table.rowAtPoint(e.getPoint()); _table.setRowSelectionInterval(_lastRow, _lastRow);
protected void _popupAction(MouseEvent e) { int row = _table.rowAtPoint(e.getPoint()); _table.setRowSelectionInterval(row, row); _showPopup(e); }
11192 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11192/da5a0dd68bcb282274a520304e64e7f255ef6c4e/DebugPanel.java/clean/drjava/src/edu/rice/cs/drjava/ui/DebugPanel.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4750, 918, 389, 16086, 1803, 12, 9186, 1133, 425, 13, 288, 1377, 509, 1027, 273, 389, 2121, 18, 492, 861, 2148, 12, 73, 18, 588, 2148, 10663, 1377, 389, 2121, 18, 542, 1999, 6233, 4006,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 4750, 918, 389, 16086, 1803, 12, 9186, 1133, 425, 13, 288, 1377, 509, 1027, 273, 389, 2121, 18, 492, 861, 2148, 12, 73, 18, 588, 2148, 10663, 1377, 389, 2121, 18, 542, 1999, 6233, 4006,...
factory.doBind("brokerId", new URI("ssl: } catch (Exception e) {
factory.doBind("brokerId", new URI("ssl: } catch (Exception e) {
public void testBindServerOptions() throws IOException { SslTransportServer sslTransportServer = null; for (int i = 0; i < 4; ++i) { final boolean wantClientAuth = ((i & 0x1) == 1); final boolean needClientAuth = ((i & 0x2) == 1); String options = "wantClientAuth=" + (wantClientAuth ? "true" : "false") + "&needClientAuth=" + (needClientAuth ? "true" : "false"); try { sslTransportServer = (SslTransportServer) factory.doBind("brokerId", new URI("ssl://localhost:61616?" + options)); } catch (Exception e) { fail("Unable to bind to address: " + e.getMessage()); } assertEquals("Created ServerSocket did not have correct wantClientAuth status.", sslTransportServer.getWantClientAuth(), wantClientAuth); assertEquals("Created ServerSocket did not have correct needClientAuth status.", sslTransportServer.getNeedClientAuth(), needClientAuth); try { sslTransportServer.stop(); } catch (Exception e) { fail("Unable to stop TransportServer: " + e.getMessage()); } } }
17032 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17032/6e34afc293d6a87963cf3613ada19c2d57b62184/SslTransportFactoryTest.java/buggy/activemq-core/src/test/java/org/apache/activemq/transport/tcp/SslTransportFactoryTest.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1842, 3357, 2081, 1320, 1435, 1216, 1860, 288, 13491, 23929, 6568, 2081, 5832, 6568, 2081, 273, 446, 31, 7734, 364, 261, 474, 277, 273, 374, 31, 277, 411, 1059, 31, 965, 77, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1842, 3357, 2081, 1320, 1435, 1216, 1860, 288, 13491, 23929, 6568, 2081, 5832, 6568, 2081, 273, 446, 31, 7734, 364, 261, 474, 277, 273, 374, 31, 277, 411, 1059, 31, 965, 77, ...
public void setAsText(String s) throws IllegalArgumentException { if(s.equals("null")) { setValue(null); } else { throw new IllegalArgumentException(); } }
public void setAsText(String s) throws IllegalArgumentException { if (s.equals("null")) setValue(null); else throw new IllegalArgumentException(); }
public void setAsText(String s) throws IllegalArgumentException { if(s.equals("null")) { setValue(null); } else { throw new IllegalArgumentException(); } }
1043 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1043/d1d54223348b2f353d3505c9de3cf685bdb5301f/PropertyEditorSupport.java/buggy/libjava/java/beans/PropertyEditorSupport.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 444, 1463, 1528, 12, 780, 272, 13, 1216, 2754, 288, 202, 202, 430, 12, 87, 18, 14963, 2932, 2011, 6, 3719, 288, 1082, 202, 542, 620, 12, 2011, 1769, 202, 202, 97, 469, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 225, 202, 482, 918, 444, 1463, 1528, 12, 780, 272, 13, 1216, 2754, 288, 202, 202, 430, 12, 87, 18, 14963, 2932, 2011, 6, 3719, 288, 1082, 202, 542, 620, 12, 2011, 1769, 202, 202, 97, 469, ...
addWarning(pg_stream.ReceiveString(4096));
addWarning(pg_stream.ReceiveString(receive_sbuf, 4096, getEncoding()));
public java.sql.ResultSet ExecSQL(String sql) throws SQLException { // added Oct 7 1998 to give us thread safety. synchronized(pg_stream) { Field[] fields = null; Vector tuples = new Vector(); byte[] buf = null; int fqp = 0; boolean hfr = false; String recv_status = null, msg; int update_count = 1; int insert_oid = 0; SQLException final_error = null; // Commented out as the backend can now handle queries // larger than 8K. Peter June 6 2000 //if (sql.length() > 8192) //throw new PSQLException("postgresql.con.toolong",sql); if (getEncoding() == null) buf = sql.getBytes(); else { try { buf = sql.getBytes(getEncoding()); } catch (UnsupportedEncodingException unse) { throw new PSQLException("postgresql.con.encoding", unse); } } try { pg_stream.SendChar('Q'); buf = sql.getBytes(); pg_stream.Send(buf); pg_stream.SendChar(0); pg_stream.flush(); } catch (IOException e) { throw new PSQLException("postgresql.con.ioerror",e); } while (!hfr || fqp > 0) { Object tup=null; // holds rows as they are recieved int c = pg_stream.ReceiveChar(); switch (c) { case 'A': // Asynchronous Notify pid = pg_stream.ReceiveInteger(4); msg = pg_stream.ReceiveString(8192); break; case 'B': // Binary Data Transfer if (fields == null) throw new PSQLException("postgresql.con.tuple"); tup = pg_stream.ReceiveTuple(fields.length, true); // This implements Statement.setMaxRows() if(maxrows==0 || tuples.size()<maxrows) tuples.addElement(tup); break; case 'C': // Command Status recv_status = pg_stream.ReceiveString(8192); // Now handle the update count correctly. if(recv_status.startsWith("INSERT") || recv_status.startsWith("UPDATE") || recv_status.startsWith("DELETE")) { try { update_count = Integer.parseInt(recv_status.substring(1+recv_status.lastIndexOf(' '))); } catch(NumberFormatException nfe) { throw new PSQLException("postgresql.con.fathom",recv_status); } if(recv_status.startsWith("INSERT")) { try { insert_oid = Integer.parseInt(recv_status.substring(1+recv_status.indexOf(' '),recv_status.lastIndexOf(' '))); } catch(NumberFormatException nfe) { throw new PSQLException("postgresql.con.fathom",recv_status); } } } if (fields != null) hfr = true; else { try { pg_stream.SendChar('Q'); pg_stream.SendChar(' '); pg_stream.SendChar(0); pg_stream.flush(); } catch (IOException e) { throw new PSQLException("postgresql.con.ioerror",e); } fqp++; } break; case 'D': // Text Data Transfer if (fields == null) throw new PSQLException("postgresql.con.tuple"); tup = pg_stream.ReceiveTuple(fields.length, false); // This implements Statement.setMaxRows() if(maxrows==0 || tuples.size()<maxrows) tuples.addElement(tup); break; case 'E': // Error Message msg = pg_stream.ReceiveString(4096); final_error = new SQLException(msg); hfr = true; break; case 'I': // Empty Query int t = pg_stream.ReceiveChar(); if (t != 0) throw new PSQLException("postgresql.con.garbled"); if (fqp > 0) fqp--; if (fqp == 0) hfr = true; break; case 'N': // Error Notification addWarning(pg_stream.ReceiveString(4096)); break; case 'P': // Portal Name String pname = pg_stream.ReceiveString(8192); break; case 'T': // MetaData Field Description if (fields != null) throw new PSQLException("postgresql.con.multres"); fields = ReceiveFields(); break; case 'Z': // backend ready for query, ignore for now :-) break; default: throw new PSQLException("postgresql.con.type",new Character((char)c)); } } if (final_error != null) throw final_error; return getResultSet(this, fields, tuples, recv_status, update_count, insert_oid); } }
46409 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46409/5383b5d8ed6da5c90bcbdb63401b7d1d75db563d/Connection.java/clean/src/interfaces/jdbc/org/postgresql/Connection.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 2252, 18, 4669, 18, 13198, 3889, 3997, 12, 780, 1847, 13, 1216, 6483, 565, 288, 202, 759, 3096, 29482, 2371, 23673, 28, 358, 8492, 584, 2650, 24179, 18, 202, 22043, 12, 8365, 67, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 2252, 18, 4669, 18, 13198, 3889, 3997, 12, 780, 1847, 13, 1216, 6483, 565, 288, 202, 759, 3096, 29482, 2371, 23673, 28, 358, 8492, 584, 2650, 24179, 18, 202, 22043, 12, 8365, 67, ...
if (others.size() != 0) { IRuntimeClasspathEntry oe[] = (IRuntimeClasspathEntry[]) others.toArray( new IRuntimeClasspathEntry[others.size()] );
Pattern pattern = Pattern.compile("^*/(\\w+\\.framework)/Resources/Java/(.*\\.jar)$");
public IRuntimeClasspathEntry[] resolveClasspath( IRuntimeClasspathEntry[] entries, ILaunchConfiguration configuration) throws CoreException { List others = new ArrayList(); List resolved = new ArrayList(); // used for duplicate removal Set allEntries = new HashSet(); // looks like we need to let super do it's thing before // we start tinkering with things ourselves entries = super.resolveClasspath(entries, configuration); // resolve WO framework/application projects ourselves, let super do the rest for (int i = 0; i < entries.length; ++i) { IRuntimeClasspathEntry entry = entries[i]; IPath archive = _getWOJavaArchive(entry); if (null != archive) { // I think this line here breaks things: (hn3000) //resolved.add(entry); if (!allEntries.contains(archive.toString())) { resolved.add( JavaRuntime.newArchiveRuntimeClasspathEntry(archive)); allEntries.add(archive.toString()); } allEntries.add(entry.toString()); } else { others.add(entry); } } // ... let super do the rest but remove duplicates from the resulting // classpath ... if (others.size() != 0) { IRuntimeClasspathEntry oe[] = (IRuntimeClasspathEntry[]) others.toArray( new IRuntimeClasspathEntry[others.size()] ); for (int i = 0; i < oe.length; ++i) { IRuntimeClasspathEntry entry = oe[i]; String ls = entry.getLocation(); IPath loc = (null == ls) ? null : new Path(ls); if (null == loc) { resolved.add(entry); } else { if (!allEntries.contains(loc)) { resolved.add(entry); allEntries.add(loc); } } } } return (IRuntimeClasspathEntry[]) resolved.toArray( new IRuntimeClasspathEntry[resolved.size()]); }
50596 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50596/f242ccb537b802c24cf9ef5a1d402800bbbe648f/WORuntimeClasspathProvider.java/buggy/projects/wolips/plugins/org.objectstyle.wolips.launching/java/org/objectstyle/wolips/launching/classpath/WORuntimeClasspathProvider.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 467, 5576, 17461, 1622, 8526, 2245, 17461, 12, 202, 202, 45, 5576, 17461, 1622, 8526, 3222, 16, 202, 202, 2627, 4760, 1750, 1664, 13, 202, 202, 15069, 30015, 288, 202, 202, 682,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 467, 5576, 17461, 1622, 8526, 2245, 17461, 12, 202, 202, 45, 5576, 17461, 1622, 8526, 3222, 16, 202, 202, 2627, 4760, 1750, 1664, 13, 202, 202, 15069, 30015, 288, 202, 202, 682,...
Logger.trace("StendhalRPZone::placeObjectAtZoneChangePoint","D","Best entry point: ("+px+","+py+") --> "+distance);
logger.debug("Best entry point: ("+px+","+py+") --> "+distance);
public void placeObjectAtZoneChangePoint(StendhalRPZone oldzone, Entity object) { if(zoneChangePoints.size()==0) { return; } String exitDirection=null; if(object.gety()<4) { exitDirection="N"; } else if(object.gety()>oldzone.getHeight()-4) { exitDirection="S"; } else if(object.getx()<4) { exitDirection="W"; } else if(object.getx()>oldzone.getWidth()-4) { exitDirection="E"; } else { // NOTE: If any of the above is true, then it just put object on the first zone change point. String[] components=zoneChangePoints.get(0).split(","); Logger.trace("StendhalRPZone::placeObjectAtZoneChangePoint","D","Player zone change default: "+components); object.setx(Integer.parseInt(components[0])); object.sety(Integer.parseInt(components[1])); return; } Logger.trace("StendhalRPZone::placeObjectAtZoneChangePoint","D","Player exit direction: "+exitDirection); int x=0; int y=0; int distance=Integer.MAX_VALUE; String minpoint=zoneChangePoints.get(0); if(exitDirection.equals("N")) { x=object.getx(); y=getHeight(); } else if(exitDirection.equals("S")) { x=object.getx(); y=0; } else if(exitDirection.equals("W")) { x=getWidth(); y=object.gety(); } else if(exitDirection.equals("E")) { x=0; y=object.gety(); } Logger.trace("StendhalRPZone::placeObjectAtZoneChangePoint","D","Player entry point: ("+x+","+y+")"); for(String point: zoneChangePoints) { String[] components=point.split(","); int px=Integer.parseInt(components[0]); int py=Integer.parseInt(components[1]); if((px-x)*(px-x)+(py-y)*(py-y)<distance) { Logger.trace("StendhalRPZone::placeObjectAtZoneChangePoint","D","Best entry point: ("+px+","+py+") --> "+distance); distance=(px-x)*(px-x)+(py-y)*(py-y); minpoint=point; } } Logger.trace("StendhalRPZone::placeObjectAtZoneChangePoint","D","Choosen entry point: ("+minpoint+") --> "+distance); String[] components=minpoint.split(","); object.setx(Integer.parseInt(components[0])); object.sety(Integer.parseInt(components[1])); }
4438 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4438/2f5a2a4a5b59a172e667611127a4c633125829e5/StendhalRPZone.java/buggy/src/games/stendhal/server/StendhalRPZone.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 918, 3166, 921, 861, 4226, 3043, 2148, 12, 510, 409, 22314, 54, 52, 4226, 1592, 3486, 16, 3887, 733, 13, 565, 288, 565, 309, 12, 3486, 3043, 5636, 18, 1467, 1435, 631, 20, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 918, 3166, 921, 861, 4226, 3043, 2148, 12, 510, 409, 22314, 54, 52, 4226, 1592, 3486, 16, 3887, 733, 13, 565, 288, 565, 309, 12, 3486, 3043, 5636, 18, 1467, 1435, 631, 20, 13, 1...
public InputStream getResourceAsStream(String name, BeanContextChild bcc) { // The resource name should not be null if(name == null) { throw new NullPointerException("Resource name can not be null"); } // The child should not be null if(bcc == null) { throw new NullPointerException("The child can not be null"); } // Load resource using the same ClassLoader as BeanContextChild specified // If NullPointerException occurs try to load it as system resource try { return bcc.getClass().getClassLoader().getResourceAsStream(name); } catch(NullPointerException e) { try { return ClassLoader.getSystemResourceAsStream(name); } catch(Exception ex) { // No success at all throw new IllegalArgumentException("Invalid resource"); } } }
54769 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54769/2ff86cce7654955efea2913c35b44a8bb53879b5/BeanContextSupport.java/clean/modules/beans/src/main/java/java/beans/beancontext/BeanContextSupport.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 5037, 20216, 12, 780, 508, 16, 7704, 1042, 1763, 16915, 13, 288, 7734, 368, 1021, 1058, 508, 1410, 486, 506, 446, 3639, 309, 12, 529, 422, 446, 13, 288, 5411, 604, 394, 10108, 293...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5037, 20216, 12, 780, 508, 16, 7704, 1042, 1763, 16915, 13, 288, 7734, 368, 1021, 1058, 508, 1410, 486, 506, 446, 3639, 309, 12, 529, 422, 446, 13, 288, 5411, 604, 394, 10108, 293...
public IASTTranslationUnit parse() { long startTime = System.currentTimeMillis(); translationUnit(); // For the debuglog to take place, you have to call // Util.setDebugging(true); // Or set debug to true in the core plugin preference log.traceLog("Parse " //$NON-NLS-1$ + (++parseCount) + ": " //$NON-NLS-1$ + (System.currentTimeMillis() - startTime) + "ms" //$NON-NLS-1$ + (parsePassed ? "" : " - parse failure")); //$NON-NLS-1$ //$NON-NLS-2$ IASTTranslationUnit result = getTranslationUnit(); nullifyTranslationUnit(); return result; }
54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/a65769ef8a2d061e23943a119d6ef9b44b0f2c30/AbstractGNUSourceCodeParser.java/buggy/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/parser/AbstractGNUSourceCodeParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 1071, 467, 9053, 6717, 2802, 1109, 1435, 288, 225, 1525, 8657, 273, 2332, 18, 2972, 28512, 5621, 225, 4794, 2802, 5621, 225, 368, 2457, 326, 1198, 1330, 358, 4862, 3166, 16, 1846, 1240, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 1071, 467, 9053, 6717, 2802, 1109, 1435, 288, 225, 1525, 8657, 273, 2332, 18, 2972, 28512, 5621, 225, 4794, 2802, 5621, 225, 368, 2457, 326, 1198, 1330, 358, 4862, 3166, 16, 1846, 1240, 3...
skipWhitespace (); dataBufferAppend (readNmtoken (isNames)); skipWhitespace (); while (!tryRead (')')) { require ('|'); dataBufferAppend ('|'); skipWhitespace (); dataBufferAppend (readNmtoken (isNames)); skipWhitespace (); } dataBufferAppend (')'); }
skipWhitespace(); dataBufferAppend(readNmtoken(isNames)); skipWhitespace(); while (!tryRead(')')) { require('|'); dataBufferAppend('|'); skipWhitespace(); dataBufferAppend(readNmtoken (isNames)); skipWhitespace(); } dataBufferAppend(')'); }
private void parseEnumeration (boolean isNames) throws Exception { dataBufferAppend ('('); // Read the first token. skipWhitespace (); dataBufferAppend (readNmtoken (isNames)); // Read the remaining tokens. skipWhitespace (); while (!tryRead (')')) { require ('|'); dataBufferAppend ('|'); skipWhitespace (); dataBufferAppend (readNmtoken (isNames)); skipWhitespace (); } dataBufferAppend (')'); }
1023 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1023/7fb7568e63c3fe14af521de4699cb37898923ca7/XmlParser.java/buggy/libjava/gnu/xml/aelfred2/XmlParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 1109, 21847, 261, 6494, 353, 1557, 13, 565, 1216, 1185, 565, 288, 202, 892, 1892, 5736, 7707, 2668, 1769, 202, 759, 2720, 326, 1122, 1147, 18, 202, 7457, 9431, 261, 1769, 202, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 1109, 21847, 261, 6494, 353, 1557, 13, 565, 1216, 1185, 565, 288, 202, 892, 1892, 5736, 7707, 2668, 1769, 202, 759, 2720, 326, 1122, 1147, 18, 202, 7457, 9431, 261, 1769, 202, ...
public int[] getRowsForPaths(TreePath[] value0) {
public int[] getRowsForPaths(TreePath[] paths) {
public int[] getRowsForPaths(TreePath[] value0) { return null; // TODO } // getRowsForPaths()
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/9e763280cf1369c9681ea91b32ae758840a76dc3/AbstractLayoutCache.java/buggy/core/src/classpath/javax/javax/swing/tree/AbstractLayoutCache.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 509, 8526, 22594, 1290, 4466, 12, 2471, 743, 8526, 460, 20, 13, 288, 202, 202, 2463, 446, 31, 368, 2660, 202, 97, 368, 22594, 1290, 4466, 1435, 2, 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, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 509, 8526, 22594, 1290, 4466, 12, 2471, 743, 8526, 460, 20, 13, 288, 202, 202, 2463, 446, 31, 368, 2660, 202, 97, 368, 22594, 1290, 4466, 1435, 2, -100, -100, -100, -100, -100...
}
codePoint = reader.getCodePoint();
private int parseACCSEC() throws DRDAProtocolException { int securityCheckCode = 0; int securityMechanism = 0; byte [] publicKeyIn = null; reader.markCollection(); int codePoint = reader.getCodePoint(); while (codePoint != -1) { switch(codePoint) { //optional case CodePoint.SECMGRNM: // this is defined to be 0 length if (reader.getDdmLength() != 0) badObjectLength(CodePoint.SECMGRNM); break; //required case CodePoint.SECMEC: checkLength(CodePoint.SECMEC, 2); securityMechanism = reader.readNetworkShort(); if (SanityManager.DEBUG) trace("Security mechanism = " + securityMechanism); // if Property.DRDA_PROP_SECURITYMECHANISM has been set, then // network server only accepts connections which use that // security mechanism. No other types of connections // are accepted. // Make check to see if this property has been set. // if set, and if the client requested security mechanism // is not the same, then return a security check code // that the server does not support/allow this security // mechanism if ( (server.getSecurityMechanism() != NetworkServerControlImpl.INVALID_OR_NOTSET_SECURITYMECHANISM) && securityMechanism != server.getSecurityMechanism()) securityCheckCode = CodePoint.SECCHKCD_NOTSUPPORTED; else { // for plain text userid,password USRIDPWD, and USRIDONL // no need of decryptionManager if (securityMechanism != CodePoint.SECMEC_USRIDPWD && securityMechanism != CodePoint.SECMEC_USRIDONL) { //this is the only other one we understand if (securityMechanism != CodePoint.SECMEC_EUSRIDPWD) securityCheckCode = CodePoint.SECCHKCD_NOTSUPPORTED; else { try { if (decryptionManager == null) decryptionManager = new DecryptionManager(); myPublicKey = decryptionManager.obtainPublicKey(); } catch (SQLException e) { println2Log(null, session.drdaID, e.getMessage()); // Local security service non-retryable error. securityCheckCode = CodePoint.SECCHKCD_0A; } } } } break; //optional (currently required for Cloudscape - may need to revisit) case CodePoint.RDBNAM: String dbname = parseRDBNAM(); Database d = session.getDatabase(dbname); if (d == null) addDatabase(dbname); else { // reset database for connection re-use d.reset(); database = d; } break; //optional - depending on security Mechanism case CodePoint.SECTKN: publicKeyIn = reader.readBytes(); break; default: invalidCodePoint(codePoint); } codePoint = reader.getCodePoint(); } // check for required CodePoint's if (securityMechanism == 0) missingCodePoint(CodePoint.SECMEC); // RESOLVE - when we look further into security we might want to // handle this part of the protocol at the session level without // requiring a database for when authentication is used but there // is no database level security if (database == null) missingCodePoint(CodePoint.RDBNAM); database.securityMechanism = securityMechanism; database.publicKeyIn = publicKeyIn; // need security token if (securityCheckCode == 0 && database.securityMechanism == CodePoint.SECMEC_EUSRIDPWD && database.publicKeyIn == null) securityCheckCode = CodePoint.SECCHKCD_SECTKNMISSING_OR_INVALID; // shouldn't have security token if (securityCheckCode == 0 && (database.securityMechanism == CodePoint.SECMEC_USRIDPWD || database.securityMechanism == CodePoint.SECMEC_USRIDONL) && database.publicKeyIn != null) securityCheckCode = CodePoint.SECCHKCD_SECTKNMISSING_OR_INVALID; if (SanityManager.DEBUG) trace("** ACCSECRD securityCheckCode is: "+securityCheckCode); // If the security check was successful set the session state to // security accesseed. Otherwise go back to attributes exchanged so we // require another ACCSEC if (securityCheckCode == 0) session.setState(session.SECACC); else session.setState(session.ATTEXC); return securityCheckCode; }
56322 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56322/977561c9de22d12b40a3a2f79a8df22ba7fc7752/DRDAConnThread.java/buggy/java/drda/org/apache/derby/impl/drda/DRDAConnThread.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 509, 1109, 31414, 11944, 1435, 1216, 225, 16801, 9793, 5752, 503, 288, 202, 474, 4373, 1564, 1085, 273, 374, 31, 202, 474, 4373, 31546, 273, 374, 31, 202, 7229, 5378, 12085, 382, 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, 3238, 509, 1109, 31414, 11944, 1435, 1216, 225, 16801, 9793, 5752, 503, 288, 202, 474, 4373, 1564, 1085, 273, 374, 31, 202, 474, 4373, 31546, 273, 374, 31, 202, 7229, 5378, 12085, 382, 27...
public static LinkedList getRoute(StaticStreamGraph ssg, FlatNode from, FlatNode to) { RawChip rawChip = ssg.getStreamGraph().getRawChip(); Layout layout = ssg.getStreamGraph().getLayout(); LinkedList route = new LinkedList(); RawTile fromCoord, toCoord; fromCoord = layout.getTile(from); toCoord = layout.getTile(to); route.add(layout.getTile(from)); if (fromCoord== null) System.out.println("From RawTile null"); int row = fromCoord.getY(); int column = fromCoord.getX(); //For now just route the packets in a stupid manner //row then column if (fromCoord.getY() != toCoord.getY()) { if (fromCoord.getY() < toCoord.getY()) { for (row = fromCoord.getY() + 1; row <= toCoord.getY(); row++) route.add(rawChip.getTile(column, row)); row--; } else { for (row = fromCoord.getY() - 1; row >= toCoord.getY(); row--) route.add(rawChip.getTile(column, row)); row++; } } //column if (fromCoord.getX() != toCoord.getX()) { if (fromCoord.getX() < toCoord.getX()) for (column = fromCoord.getX() + 1; column <= toCoord.getX(); column++) route.add(rawChip.getTile(column, row)); else for (column = fromCoord.getX() - 1; column >= toCoord.getX(); column--) route.add(rawChip.getTile(column, row)); } //printRoute(from, to, route); return route; }
5955 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5955/9157186c2a764caf5864b9d5e7d1a1aa930239a6/Router.java/buggy/streams/src/at/dms/kjc/spacedynamic/Router.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1071, 760, 10688, 13245, 12, 5788, 1228, 4137, 272, 1055, 16, 20396, 907, 628, 16, 20396, 907, 358, 13, 288, 202, 4809, 782, 625, 1831, 782, 625, 273, 272, 1055, 18, 588, 1228, 4137, 7675, 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, 1071, 760, 10688, 13245, 12, 5788, 1228, 4137, 272, 1055, 16, 20396, 907, 628, 16, 20396, 907, 358, 13, 288, 202, 4809, 782, 625, 1831, 782, 625, 273, 272, 1055, 18, 588, 1228, 4137, 7675, 5...
String referencedClassName = property.getReferencedDomainClass().getFullName();
String tableName = calculateTableForMany(property); Table t = mappings.addTable( mappings.getSchemaName(), mappings.getCatalogName(), tableName, null, false ); collection.setCollectionTable(t);
private static void bindCollection(GrailsDomainClassProperty property, Collection collection, PersistentClass owner, Mappings mappings) { // set role collection.setRole( StringHelper.qualify( property.getDomainClass().getFullName() , property.getName() ) ); // configure eager fetching if(property.getFetchMode() == GrailsDomainClassProperty.FETCH_EAGER) { collection.setFetchMode(FetchMode.JOIN); } else { collection.setFetchMode( FetchMode.DEFAULT ); } // if its a one-to-many mapping if(property.isOneToMany() || property.isManyToMany()) { OneToMany oneToMany = new OneToMany( collection.getOwner() ); collection.setElement( oneToMany );/* if(property.isBidirectional()) { collection.setReferencedPropertyName( property.getOtherSide().getName() ); }*/ bindOneToMany( property, oneToMany, mappings ); } else { String referencedClassName = property.getReferencedDomainClass().getFullName(); Table table = mappings.addTable( mappings.getSchemaName(), mappings.getCatalogName(), namingStrategy.classToTableName(referencedClassName), null, false ); collection.setCollectionTable(table); } // setup second pass mappings.addSecondPass( new GrailsCollectionSecondPass(property, mappings, collection) ); }
47932 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47932/8d95f969eac0dc682fb80db98ab561d14174c8f1/GrailsDomainBinder.java/buggy/grails/src/persistence/org/codehaus/groovy/grails/orm/hibernate/cfg/GrailsDomainBinder.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 760, 918, 1993, 2532, 12, 14571, 14573, 3748, 797, 1396, 1272, 16, 2200, 1849, 16, 11049, 797, 3410, 16, 1635, 4675, 7990, 13, 288, 9506, 202, 759, 444, 2478, 202, 202, 5548, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 918, 1993, 2532, 12, 14571, 14573, 3748, 797, 1396, 1272, 16, 2200, 1849, 16, 11049, 797, 3410, 16, 1635, 4675, 7990, 13, 288, 9506, 202, 759, 444, 2478, 202, 202, 5548, ...
pushFollow(FOLLOW_opt_semicolon_in_import_statement217);
if (failed) return ; pushFollow(FOLLOW_opt_semicolon_in_import_statement224);
public void import_statement() throws RecognitionException { String name = null; try { // D:\\dev\\jbossrules\\trunk\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:325:4: ( 'import' name= import_name opt_semicolon ) // D:\\dev\\jbossrules\\trunk\\drools-compiler\\src\\main\\resources\\org\\drools\\lang\\DRL.g:325:4: 'import' name= import_name opt_semicolon { match(input,29,FOLLOW_29_in_import_statement211); pushFollow(FOLLOW_import_name_in_import_statement215); name=import_name(); _fsp--; pushFollow(FOLLOW_opt_semicolon_in_import_statement217); opt_semicolon(); _fsp--; if (packageDescr != null) packageDescr.addImport( name ); } } catch (RecognitionException re) { reportError(re); recover(input,re); } finally { } return ; }
31577 /local/tlutelli/issta_data/temp/all_java3context/java/2006_temp/2006/31577/6b34eb3854fdc06f31034567ebdf72ff28c6c11a/DRLParser.java/clean/drools-compiler/src/main/java/org/drools/lang/DRLParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1930, 67, 11516, 1435, 1216, 9539, 288, 6647, 514, 508, 273, 446, 31, 3639, 775, 288, 5411, 368, 463, 31027, 5206, 1695, 10649, 8464, 7482, 1695, 26133, 1695, 12215, 17, 9576, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1930, 67, 11516, 1435, 1216, 9539, 288, 6647, 514, 508, 273, 446, 31, 3639, 775, 288, 5411, 368, 463, 31027, 5206, 1695, 10649, 8464, 7482, 1695, 26133, 1695, 12215, 17, 9576, ...
nullLog);
nullLog, null);
private static CSearchPattern createNamespacePattern(String patternString, LimitTo limitTo, int matchMode, boolean caseSensitive) { if( limitTo == ALL_OCCURRENCES ){ OrPattern orPattern = new OrPattern(); orPattern.addPattern( createNamespacePattern( patternString, DECLARATIONS, matchMode, caseSensitive ) ); orPattern.addPattern( createNamespacePattern( patternString, DEFINITIONS, matchMode, caseSensitive ) ); orPattern.addPattern( createNamespacePattern( patternString, REFERENCES, matchMode, caseSensitive ) ); return orPattern; } IScanner scanner = null; try { scanner = ParserFactory.createScanner( new StringReader(patternString), "TEXT", //$NON-NLS-1$ new ScannerInfo(), ParserMode.QUICK_PARSE, ParserLanguage.CPP, callback, nullLog); } catch (ParserFactoryError e) { } LinkedList list = scanForNames( scanner, null ); char [] name = (char []) list.removeLast(); char [][] qualifications = new char [0][]; return new NamespaceDeclarationPattern( name, (char[][]) list.toArray( qualifications ), matchMode, limitTo, caseSensitive ); }
54911 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54911/68365e4ac0dcf1f0e969c7f6ab7b763b87c43216/CSearchPattern.java/buggy/core/org.eclipse.cdt.core/search/org/eclipse/cdt/internal/core/search/matching/CSearchPattern.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 760, 385, 2979, 3234, 752, 3402, 3234, 12, 780, 1936, 780, 16, 7214, 774, 1800, 774, 16, 509, 845, 2309, 16, 1250, 20975, 13, 288, 202, 202, 430, 12, 1800, 774, 422, 8061, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 385, 2979, 3234, 752, 3402, 3234, 12, 780, 1936, 780, 16, 7214, 774, 1800, 774, 16, 509, 845, 2309, 16, 1250, 20975, 13, 288, 202, 202, 430, 12, 1800, 774, 422, 8061, ...
return new String[]{ ComponentCreationDataModel.PROJECT_NAME, ComponentCreationDataModel.COMPONENT_NAME, ComponentCreationDataModel.COMPONENT_VERSION, WTPOperationDataModel.NESTED_MODEL_VALIDATION_HOOK, J2EEComponentCreationDataModel.ADD_TO_EAR}; }
return new String[] { PROJECT_NAME, COMPONENT_NAME, COMPONENT_VERSION, ADD_TO_EAR }; }
protected String[] getValidationPropertyNames() { return new String[]{ ComponentCreationDataModel.PROJECT_NAME, ComponentCreationDataModel.COMPONENT_NAME, ComponentCreationDataModel.COMPONENT_VERSION, WTPOperationDataModel.NESTED_MODEL_VALIDATION_HOOK, J2EEComponentCreationDataModel.ADD_TO_EAR}; }
8196 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8196/59b6004d2898a63ab8beb09f095b3e971307dd92/AppClientComponentCreationWizardPage.java/clean/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/wizard/AppClientComponentCreationWizardPage.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1117, 514, 8526, 23315, 29932, 1435, 288, 202, 202, 2463, 394, 514, 63, 7073, 9506, 202, 1841, 9906, 26349, 18, 17147, 67, 1985, 16, 4697, 202, 1841, 9906, 26349, 18, 22922, 67, 1985...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1117, 514, 8526, 23315, 29932, 1435, 288, 202, 202, 2463, 394, 514, 63, 7073, 9506, 202, 1841, 9906, 26349, 18, 17147, 67, 1985, 16, 4697, 202, 1841, 9906, 26349, 18, 22922, 67, 1985...
g.fillRect( 1 + x + iseq * gap, y, gap, height );
g.fillRect( 1 + x + iseq * gap, y, Math.max( gap, 1 ), height );
protected void drawBarShape( Graphics g, int x, int y, int width, int height, int iseq, int nseq ) { int gap = ( width - 2 ) / nseq; g.fillRect( 1 + x + iseq * gap, y, gap, height ); }
48494 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48494/0b67dd8cc49f492970063cf59eb19e0cd8f6346b/BarStyles.java/buggy/topcat/src/main/uk/ac/starlink/topcat/plot/BarStyles.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 2398, 4750, 918, 3724, 5190, 8500, 12, 16830, 314, 16, 509, 619, 16, 509, 677, 16, 29159, 509, 1835, 16, 509, 2072, 16, 29159, 509, 277, 5436, 16, 509, 290, 5436, 262, 288, 7734, 509, 9300, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 2398, 4750, 918, 3724, 5190, 8500, 12, 16830, 314, 16, 509, 619, 16, 509, 677, 16, 29159, 509, 1835, 16, 509, 2072, 16, 29159, 509, 277, 5436, 16, 509, 290, 5436, 262, 288, 7734, 509, 9300, ...
printType((SnmpObjectType) type, indent);
printType((SnmpObjectType) type, indent, smiVersion);
private void printType(MibType type, String indent) { MibType refType; Constraint refCons; Constraint typeCons; SequenceType seqType; SequenceOfType seqOfType; if (type.getReferenceSymbol() != null) { os.print(type.getReferenceSymbol().getName()); refType = type.getReferenceSymbol().getType(); refCons = getConstraint(refType); typeCons = getConstraint(type); if (typeCons != null && typeCons != refCons) { printConstraint(type, indent); } } else if (type instanceof SequenceType) { seqType = (SequenceType) type; os.println("SEQUENCE {"); os.print(indent + " "); printTypeElements(seqType.getAllElements(), indent + " "); os.println(); os.print(indent); os.print("}"); } else if (type instanceof SequenceOfType) { seqOfType = (SequenceOfType) type; os.print("SEQUENCE "); if (seqOfType.getConstraint() != null) { os.print("("); os.print(seqOfType.getConstraint()); os.print(") "); } os.print("OF "); printType(seqOfType.getElementType(), indent); } else if (type instanceof IntegerType) { os.print("INTEGER"); printConstraint(type, indent); } else if (type instanceof BitSetType) { os.print("BITS"); printConstraint(type, indent); } else if (type instanceof StringType) { os.print("OCTET STRING"); printConstraint(type, indent); } else if (type.isPrimitive()) { os.print(type.getName()); } else if (type instanceof SnmpModuleIdentity) { printType((SnmpModuleIdentity) type, indent); } else if (type instanceof SnmpObjectIdentity) { printType((SnmpObjectIdentity) type, indent); } else if (type instanceof SnmpObjectType) { printType((SnmpObjectType) type, indent); } else if (type instanceof SnmpNotificationType) { printType((SnmpNotificationType) type, indent); } else if (type instanceof SnmpTrapType) { printType((SnmpTrapType) type, indent); } else if (type instanceof SnmpTextualConvention) { printType((SnmpTextualConvention) type, indent); } else if (type instanceof SnmpObjectGroup) { printType((SnmpObjectGroup) type, indent); } else if (type instanceof SnmpNotificationGroup) { printType((SnmpNotificationGroup) type, indent); } else if (type instanceof SnmpModuleCompliance) { printType((SnmpModuleCompliance) type, indent); } else if (type instanceof SnmpAgentCapabilities) { printType((SnmpAgentCapabilities) type, indent); } else { os.print("-- ERROR: type definition unknown"); } }
48557 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48557/5fbfded11460d18b8c6def8234ad564a8b2a50e4/MibWriter.java/buggy/src/java/net/percederberg/mibble/MibWriter.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 3238, 918, 1172, 559, 12, 49, 495, 559, 618, 16, 514, 3504, 13, 288, 3639, 490, 495, 559, 540, 1278, 559, 31, 3639, 10770, 1377, 1278, 9054, 31, 3639, 10770, 1377, 618, 9054, 31, 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, 918, 1172, 559, 12, 49, 495, 559, 618, 16, 514, 3504, 13, 288, 3639, 490, 495, 559, 540, 1278, 559, 31, 3639, 10770, 1377, 1278, 9054, 31, 3639, 10770, 1377, 618, 9054, 31, 3639, ...
return RubyFloat.m_newFloat(getRuby(), getDoubleValue() + getDoubleValue());
return RubyFloat.m_newFloat(getRuby(), getDoubleValue() + other.getDoubleValue());
public RubyNumeric op_plus(RubyNumeric other) { return RubyFloat.m_newFloat(getRuby(), getDoubleValue() + getDoubleValue()); }
47619 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47619/09d14a481cf7e28332c61c038c7d4b468854d38d/RubyFloat.java/clean/org/jruby/RubyFloat.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 19817, 9902, 1061, 67, 10103, 12, 54, 10340, 9902, 1308, 13, 288, 3639, 327, 19817, 4723, 18, 81, 67, 2704, 4723, 12, 588, 54, 10340, 9334, 16097, 620, 1435, 397, 1308, 18, 588, 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, 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, 19817, 9902, 1061, 67, 10103, 12, 54, 10340, 9902, 1308, 13, 288, 3639, 327, 19817, 4723, 18, 81, 67, 2704, 4723, 12, 588, 54, 10340, 9334, 16097, 620, 1435, 397, 1308, 18, 588, 5...
l.update(o);
l.update(new MatcherEvent(o));
public void update(byte b) { buffer[ndx++] = b; count++; if (ndx < config.blockLength) { // We have not seen a full block since the last match. return; } else if (ndx == config.blockLength) { config.weakSum.check(buffer, 0, config.blockLength); } else { config.weakSum.roll(b); } Long oldOffset = hashSearch(buffer, ndx - config.blockLength, config.blockLength); if (oldOffset != null) { if (ndx > config.blockLength) { DataBlock d = new DataBlock(count - ndx, buffer, 0, ndx - config.blockLength); Offsets o = new Offsets(oldOffset.longValue(), count-config.blockLength, config.blockLength); for (Iterator it = listeners.listIterator(); it.hasNext(); ) { MatcherListener l = (MatcherListener) it.next(); l.update(d); l.update(o); } } else { Offsets o = new Offsets(oldOffset.longValue(), count-config.blockLength, config.blockLength); for (Iterator it = listeners.listIterator(); it.hasNext(); ) { MatcherListener l = (MatcherListener) it.next(); l.update(o); } } ndx = 0; } else if (ndx == buffer.length) { DataBlock d = new DataBlock(count - ndx, buffer, 0, buffer.length - (config.blockLength-1)); for (Iterator it = listeners.listIterator(); it.hasNext(); ) { MatcherListener l = (MatcherListener) it.next(); l.update(d); } System.arraycopy(buffer, buffer.length - (config.blockLength-1), buffer, 0, config.blockLength-1); ndx = config.blockLength - 1; } }
964 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/964/bf6794f2fe20539c6ad99b318920770e903ed128/MatcherStream.java/buggy/source/org/metastatic/rsync/MatcherStream.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 565, 1071, 918, 1089, 12, 7229, 324, 13, 288, 1377, 1613, 63, 4880, 92, 9904, 65, 273, 324, 31, 1377, 1056, 9904, 31, 1377, 309, 261, 4880, 92, 411, 642, 18, 2629, 1782, 13, 288, 540, 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, 565, 1071, 918, 1089, 12, 7229, 324, 13, 288, 1377, 1613, 63, 4880, 92, 9904, 65, 273, 324, 31, 1377, 1056, 9904, 31, 1377, 309, 261, 4880, 92, 411, 642, 18, 2629, 1782, 13, 288, 540, 368,...
values.put(key, ((String)values.get(key))+";"+value);
values.put(key, ((String)values.get(key))+ ';' +value);
public synchronized void put(String key, String value) { int idx; if(value == null) return; if((idx = key.indexOf(MULTI_LEVEL_CHAR)) == -1) { String x = (String) values.get(key); if(x == null) { values.put(key, value); } else { values.put(key, ((String)values.get(key))+";"+value); } } else { String before = key.substring(0, idx); String after = key.substring(idx+1); SimpleFieldSet fs = null; if(subsets == null) subsets = new HashMap(); fs = (SimpleFieldSet) (subsets.get(before)); if(fs == null) { fs = new SimpleFieldSet(); subsets.put(before, fs); } fs.put(after, value); } }
49933 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49933/62fd59041864b4ed1f43adc676de6bfb5ea977f3/SimpleFieldSet.java/clean/src/freenet/support/SimpleFieldSet.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 3852, 918, 1378, 12, 780, 498, 16, 514, 460, 13, 288, 202, 202, 474, 2067, 31, 202, 202, 430, 12, 1132, 422, 446, 13, 327, 31, 202, 202, 430, 12443, 3465, 273, 498, 18, 31...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3852, 918, 1378, 12, 780, 498, 16, 514, 460, 13, 288, 202, 202, 474, 2067, 31, 202, 202, 430, 12, 1132, 422, 446, 13, 327, 31, 202, 202, 430, 12443, 3465, 273, 498, 18, 31...
public org.quickfix.field.UnderlyingSecurityAltID get(org.quickfix.field.UnderlyingSecurityAltID value)
public quickfix.field.UnderlyingSecurityAltID get(quickfix.field.UnderlyingSecurityAltID value)
public org.quickfix.field.UnderlyingSecurityAltID get(org.quickfix.field.UnderlyingSecurityAltID value) throws FieldNotFound { getField(value); return value; }
8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/SecurityStatus.java/clean/src/java/src/quickfix/fix44/SecurityStatus.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 9549, 904, 18, 1518, 18, 14655, 6291, 4368, 10655, 734, 336, 12, 19525, 904, 18, 1518, 18, 14655, 6291, 4368, 10655, 734, 225, 460, 13, 565, 1216, 2286, 2768, 225, 288, 5031, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 9549, 904, 18, 1518, 18, 14655, 6291, 4368, 10655, 734, 336, 12, 19525, 904, 18, 1518, 18, 14655, 6291, 4368, 10655, 734, 225, 460, 13, 565, 1216, 2286, 2768, 225, 288, 5031, 12, ...
returnAST = letVarBinding_AST; } finally { traceOut("letVarBinding");
letVarBinding_AST= (org.exist.xquery.parser.XQueryAST)astFactory.make( (new ASTArray(2)).add((org.exist.xquery.parser.XQueryAST)astFactory.create(VARIABLE_BINDING,varName)).add(letVarBinding_AST)); currentAST.root = letVarBinding_AST; currentAST.child = letVarBinding_AST!=null &&letVarBinding_AST.getFirstChild()!=null ? letVarBinding_AST.getFirstChild() : letVarBinding_AST; currentAST.advanceChildToEnd();
public final void letVarBinding() throws RecognitionException, TokenStreamException { traceIn("letVarBinding"); try { // debugging returnAST = null; ASTPair currentAST = new ASTPair(); org.exist.xquery.parser.XQueryAST letVarBinding_AST = null; String varName; match(DOLLAR); varName=qName(); { switch ( LA(1)) { case LITERAL_as: { typeDeclaration(); astFactory.addASTChild(currentAST, returnAST); break; } case COLON: { break; } default: { throw new NoViableAltException(LT(1), getFilename()); } } } match(COLON); match(EQ); exprSingle(); astFactory.addASTChild(currentAST, returnAST); if ( inputState.guessing==0 ) { letVarBinding_AST = (org.exist.xquery.parser.XQueryAST)currentAST.root; letVarBinding_AST= (org.exist.xquery.parser.XQueryAST)astFactory.make( (new ASTArray(2)).add((org.exist.xquery.parser.XQueryAST)astFactory.create(VARIABLE_BINDING,varName)).add(letVarBinding_AST)); currentAST.root = letVarBinding_AST; currentAST.child = letVarBinding_AST!=null &&letVarBinding_AST.getFirstChild()!=null ? letVarBinding_AST.getFirstChild() : letVarBinding_AST; currentAST.advanceChildToEnd(); } letVarBinding_AST = (org.exist.xquery.parser.XQueryAST)currentAST.root; returnAST = letVarBinding_AST; } finally { // debugging traceOut("letVarBinding"); } }
2909 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2909/848376fedfdb64086be7a20004c255cefe7b1015/XQueryParser.java/buggy/src/org/exist/xquery/parser/XQueryParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 727, 918, 2231, 1537, 5250, 1435, 1216, 9539, 16, 3155, 1228, 503, 288, 9506, 202, 5129, 382, 2932, 1810, 1537, 5250, 8863, 202, 202, 698, 288, 368, 10450, 1082, 202, 2463, 9053...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 727, 918, 2231, 1537, 5250, 1435, 1216, 9539, 16, 3155, 1228, 503, 288, 9506, 202, 5129, 382, 2932, 1810, 1537, 5250, 8863, 202, 202, 698, 288, 368, 10450, 1082, 202, 2463, 9053...
List<IntentionAction> result = new ArrayList<IntentionAction>();
public IntentionAction[] getFixes() { List<IntentionAction> result = new ArrayList<IntentionAction>(); final AntProject project = getElement().getAntProject(); result.add(new AntCreateTargetAction(this)); for (PsiElement child : project.getChildren()) { if (child instanceof AntImport) { AntFile importedFile = ((AntImport)child).getFile(); if (importedFile != null) { result.add(new AntCreateTargetAction(this, importedFile)); } } } return result.toArray(new IntentionAction[result.size()]); }
17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/79cbc21574a634defb76047f777774a75b5f20b3/AntTargetReference.java/clean/plugins/ant/src/com/intellij/lang/ant/psi/impl/reference/AntTargetReference.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 3094, 5054, 1803, 8526, 2812, 697, 281, 1435, 288, 4202, 727, 18830, 4109, 1984, 273, 7426, 7675, 588, 14925, 4109, 5621, 565, 563, 18, 1289, 12, 2704, 18830, 1684, 2326, 1803, 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, 1071, 3094, 5054, 1803, 8526, 2812, 697, 281, 1435, 288, 4202, 727, 18830, 4109, 1984, 273, 7426, 7675, 588, 14925, 4109, 5621, 565, 563, 18, 1289, 12, 2704, 18830, 1684, 2326, 1803, 12, ...
switch (token) { case IDENTIFIER:
if (token == IDENTIFIER)
private String parseIdentifier() throws IOException { int token = parseToken(); switch (token) { case IDENTIFIER: return _lexeme; case DEFAULT: case CLASS: case PROTECTED: case PUBLIC: case FUNCTION: case LIST: case CASE: case TRUE: case FALSE: case RETURN: case ECHO: case AND_RES: case OR_RES: case XOR_RES: case REQUIRE: return _lexeme; default: throw error(L.l("expected identifier at {0}.", tokenName(token))); } }
3863 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3863/44480f02dff82ba25e5643f2a5564399e6953d6e/PhpParser.java/clean/quercus/src/main/java/com/caucho/quercus/parser/PhpParser.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 3238, 514, 1109, 3004, 1435, 565, 1216, 1860, 225, 288, 565, 509, 1147, 273, 1109, 1345, 5621, 565, 1620, 261, 2316, 13, 288, 565, 648, 26765, 30, 1377, 327, 389, 4149, 4698, 31, 565, 6...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 3238, 514, 1109, 3004, 1435, 565, 1216, 1860, 225, 288, 565, 509, 1147, 273, 1109, 1345, 5621, 565, 1620, 261, 2316, 13, 288, 565, 648, 26765, 30, 1377, 327, 389, 4149, 4698, 31, 565, 6...
public void mT34() throws RecognitionException { int T34_StartIndex = input.index(); try { int type = T34; int start = getCharIndex(); int line = getLine(); int charPosition = getCharPositionInLine(); int channel = Token.DEFAULT_CHANNEL; if ( backtracking>0 && alreadyParsedRule(input, 20) ) { return ; } // C:\Projects\jboss-rules-new\drools-compiler\src\main\resources\org\drools\lang\drl.g:25:7: ( 'no-loop' ) // C:\Projects\jboss-rules-new\drools-compiler\src\main\resources\org\drools\lang\drl.g:25:7: 'no-loop' { match("no-loop"); if (failed) return ; } if ( token==null ) {emit(type,line,charPosition,channel,start,getCharIndex()-1);} } finally { if ( backtracking>0 ) { memoize(input, 20, T34_StartIndex); } } }
6736 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6736/e3fb9256ae6e5fcb8c78a2c3dbd47f678d9b1287/RuleParserLexer.java/buggy/drools-compiler/src/main/java/org/drools/lang/RuleParserLexer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 21115, 5026, 1435, 1216, 9539, 288, 3639, 509, 399, 5026, 67, 16792, 273, 810, 18, 1615, 5621, 3639, 775, 288, 5411, 509, 618, 273, 399, 5026, 31, 5411, 509, 787, 273, 23577, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 21115, 5026, 1435, 1216, 9539, 288, 3639, 509, 399, 5026, 67, 16792, 273, 810, 18, 1615, 5621, 3639, 775, 288, 5411, 509, 618, 273, 399, 5026, 31, 5411, 509, 787, 273, 23577, ...
txtRadius = new TextEditorComposite( cmpContent, SWT.BORDER
txtRadius = new LocalizedNumberEditorComposite( cmpContent, SWT.BORDER
private void placeComponents( ) { // Layout for the content composite GridLayout glContent = new GridLayout( 2, true ); glContent.verticalSpacing = 0; glContent.horizontalSpacing = 10; glContent.marginHeight = 7; glContent.marginWidth = 7; // Main content composite this.setLayout( glContent ); // Composite for Content cmpContent = new Composite( this, SWT.NONE ); GridData gdCMPContent = new GridData( GridData.FILL_HORIZONTAL ); cmpContent.setLayoutData( gdCMPContent ); cmpContent.setLayout( new GridLayout( 2, false ) ); Label lblRadius = new Label( cmpContent, SWT.NONE ); GridData gdLBLRadius = new GridData( GridData.HORIZONTAL_ALIGN_END ); lblRadius.setLayoutData( gdLBLRadius ); lblRadius.setText( Messages.getString( "MeterSeriesAttributeComposite.Lbl.Radius" ) ); //$NON-NLS-1$ txtRadius = new TextEditorComposite( cmpContent, SWT.BORDER | SWT.SINGLE ); GridData gdTXTRadius = new GridData( GridData.FILL_HORIZONTAL ); txtRadius.setText( String.valueOf( series.getDial( ).getRadius( ) ) ); txtRadius.setLayoutData( gdTXTRadius ); txtRadius.addListener( this ); Label lblStartAngle = new Label( cmpContent, SWT.NONE ); GridData gdLBLStartAngle = new GridData( GridData.HORIZONTAL_ALIGN_END ); lblStartAngle.setLayoutData( gdLBLStartAngle ); lblStartAngle.setText( Messages.getString( "MeterSeriesAttributeComposite.Lbl.StartAngle" ) ); //$NON-NLS-1$ iscStartAngle = new IntegerSpinControl( cmpContent, SWT.NONE, (int) series.getDial( ).getStartAngle( ) ); GridData gdISCStartAngle = new GridData( GridData.FILL_HORIZONTAL ); iscStartAngle.setLayoutData( gdISCStartAngle ); iscStartAngle.setValue( (int) ( series.getDial( ).getStartAngle( ) ) ); iscStartAngle.setMinimum( -360 ); iscStartAngle.setMaximum( 360 ); iscStartAngle.addListener( this ); Label lblStopAngle = new Label( cmpContent, SWT.NONE ); GridData gdLBLStopAngle = new GridData( GridData.HORIZONTAL_ALIGN_END ); lblStopAngle.setLayoutData( gdLBLStopAngle ); lblStopAngle.setText( Messages.getString( "MeterSeriesAttributeComposite.Lbl.StopAngle" ) ); //$NON-NLS-1$ iscStopAngle = new IntegerSpinControl( cmpContent, SWT.NONE, (int) series.getDial( ).getStopAngle( ) ); GridData gdISCStopAngle = new GridData( GridData.FILL_HORIZONTAL ); iscStopAngle.setLayoutData( gdISCStopAngle ); iscStopAngle.setValue( (int) ( series.getDial( ).getStopAngle( ) ) ); iscStopAngle.setMinimum( -360 ); iscStopAngle.setMaximum( 360 ); iscStopAngle.addListener( this ); cmpButton = new Composite( cmpContent, SWT.NONE ); GridData gdCMPButton = new GridData( GridData.FILL_HORIZONTAL ); gdCMPButton.horizontalSpan = 2; cmpButton.setLayoutData( gdCMPButton ); cmpButton.setLayout( new GridLayout( 2, true ) ); btnTicks = new Button( cmpButton, SWT.PUSH ); GridData gdBTNTicks = new GridData( GridData.FILL_HORIZONTAL ); btnTicks.setLayoutData( gdBTNTicks ); btnTicks.setText( Messages.getString( "MeterSeriesAttributeComposite.Lbl.DialTicks" ) );//$NON-NLS-1$ btnTicks.addSelectionListener( this ); btnScale = new Button( cmpButton, SWT.PUSH ); GridData gdBTNScale = new GridData( GridData.FILL_HORIZONTAL ); btnScale.setLayoutData( gdBTNScale ); btnScale.setText( Messages.getString( "MeterSeriesAttributeComposite.Lbl.DialScale" ) );//$NON-NLS-1$ btnScale.addSelectionListener( this ); // Layout for the Needle group GridLayout glNeedle = new GridLayout( 1, true ); glNeedle.verticalSpacing = 0; glNeedle.marginWidth = 10; glNeedle.marginHeight = 0; // Needle grpNeedle = new Group( this, SWT.NONE ); GridData gdGRPNeedle = new GridData( GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_BEGINNING ); gdGRPNeedle.heightHint = 93; grpNeedle.setLayoutData( gdGRPNeedle ); grpNeedle.setText( Messages.getString( "MeterSeriesAttributeSheetImpl.Lbl.Needle" ) );//$NON-NLS-1$ grpNeedle.setLayout( glNeedle ); liacNeedle = new LineAttributesComposite( grpNeedle, SWT.NONE, wizardContext, series.getNeedle( ).getLineAttributes( ), true, true, false, false ); GridData gdLIACNeedle = new GridData( GridData.FILL_HORIZONTAL ); gdLIACNeedle.horizontalIndent = 24; liacNeedle.setLayoutData( gdLIACNeedle ); liacNeedle.addListener( this ); cmbHeadStyle = new HeadStyleAttributeComposite( grpNeedle, SWT.NONE, series.getNeedle( ).getDecorator( ) ); GridData gdCMBHeadStyle = new GridData( GridData.FILL_HORIZONTAL ); cmbHeadStyle.setLayoutData( gdCMBHeadStyle ); cmbHeadStyle.addListener( this ); }
46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/d2b70963deda52802fb91e4162be11f6dfa733e4/MeterSeriesAttributeComposite.java/buggy/chart/org.eclipse.birt.chart.ui.extension/src/org/eclipse/birt/chart/ui/swt/series/MeterSeriesAttributeComposite.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1152, 918, 3166, 7171, 12, 262, 202, 95, 202, 202, 759, 9995, 364, 326, 913, 9635, 202, 202, 6313, 3744, 5118, 1350, 273, 394, 7145, 3744, 12, 576, 16, 638, 11272, 202, 202, 7043, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3166, 7171, 12, 262, 202, 95, 202, 202, 759, 9995, 364, 326, 913, 9635, 202, 202, 6313, 3744, 5118, 1350, 273, 394, 7145, 3744, 12, 576, 16, 638, 11272, 202, 202, 7043, ...
protected void openTaskEditor() { // get the active page so that we can reuse it IWorkbenchPage page = MylarTaskListPlugin.getDefault().getWorkbench().getActiveWorkbenchWindow() .getActivePage(); // if we couldn't get a page, get out if (page == null) { return; } IEditorInput input = new TaskEditorInput(this); try { // try to open an editor on the input task page.openEditor(input, MylarTaskListPrefConstants.TASK_EDITOR_ID); } catch (PartInitException ex) { MylarStatusHandler.log(ex, "open failed"); } }
51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/1245a92f28a2990bae8373c09891556a69268c75/Task.java/clean/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/internal/Task.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1117, 6459, 3190, 2174, 6946, 1435, 95, 202, 202, 759, 588, 5787, 3535, 7267, 10370, 270, 91, 557, 304, 266, 1202, 305, 202, 202, 45, 2421, 22144, 1964, 2433, 33, 12062, 7901, 2174, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 1117, 6459, 3190, 2174, 6946, 1435, 95, 202, 202, 759, 588, 5787, 3535, 7267, 10370, 270, 91, 557, 304, 266, 1202, 305, 202, 202, 45, 2421, 22144, 1964, 2433, 33, 12062, 7901, 2174, ...
if (arg.name == null) { getRuby().getClasses().getClassMap().foreach(new FindClassPathMapMethod(), arg); }
if (arg.name == null) { getRuby().getClasses().getClassMap().foreach(new FindClassPathMapMethod(), arg); }
public RubyObject findClassPath() { FindClassPathResult arg = new FindClassPathResult(); arg.klass = this; arg.track = getRuby().getClasses().getObjectClass(); arg.prev = null; if (getRuby().getClasses().getObjectClass().getInstanceVariables() != null) { getRuby().getClasses().getObjectClass().getInstanceVariables().foreach( new FindClassPathMapMethod(), arg); } if (arg.name == null) { getRuby().getClasses().getClassMap().foreach(new FindClassPathMapMethod(), arg); } if (arg.name != null) { getInstanceVariables().put(getRuby().intern("__classpath__"), arg.path); return arg.path; } return getRuby().getNil(); }
45827 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45827/0a7181933af700ea8025a4197f3a5ebcc08333c3/RubyModule.java/clean/org/jruby/RubyModule.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 19817, 921, 1104, 22158, 1435, 288, 202, 202, 3125, 22158, 1253, 1501, 273, 394, 4163, 22158, 1253, 5621, 202, 202, 3175, 18, 22626, 273, 333, 31, 202, 202, 3175, 18, 4101, 273,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 19817, 921, 1104, 22158, 1435, 288, 202, 202, 3125, 22158, 1253, 1501, 273, 394, 4163, 22158, 1253, 5621, 202, 202, 3175, 18, 22626, 273, 333, 31, 202, 202, 3175, 18, 4101, 273,...
ArrayList lines = new ArrayList(); ArrayList errors = new ArrayList();
ArrayList<String> lines = new ArrayList<String>(); ArrayList<String> errors = new ArrayList<String>();
public boolean isLocallyModified(String filename) { String[] command = new String[] { "svn", "status", filename }; ArrayList lines = new ArrayList(); ArrayList errors = new ArrayList(); int status = ProcessUtilities.backQuote(getRoot(), command, lines, errors); for (int i = 0; i < lines.size(); ++i) { String line = (String) lines.get(i); if (line.startsWith("M")) { return true; } } return false; }
10883 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10883/f411b42ba4b57cdb26ef8b9350f88c2390902e52/Subversion.java/buggy/trunk/src/e/scm/Subversion.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 1250, 353, 1333, 1230, 4575, 12, 780, 1544, 13, 288, 3639, 514, 8526, 1296, 273, 394, 514, 8526, 288, 315, 31505, 3113, 315, 2327, 3113, 1544, 289, 31, 3639, 2407, 2362, 273, 394, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 353, 1333, 1230, 4575, 12, 780, 1544, 13, 288, 3639, 514, 8526, 1296, 273, 394, 514, 8526, 288, 315, 31505, 3113, 315, 2327, 3113, 1544, 289, 31, 3639, 2407, 2362, 273, 394, ...
public void setupBuiltInMacros(IScannerData scannerData, ParserLanguage language) { this.language = language;
public void setupBuiltInMacros(IScannerData scannerData) {
public void setupBuiltInMacros(IScannerData scannerData, ParserLanguage language) { this.language = language; if( language == ParserLanguage.CPP ) if( scannerData.getScanner().getDefinition( IScanner.__CPLUSPLUS ) == null ) scannerData.getScanner().addDefinition( IScanner.__CPLUSPLUS, new ObjectMacroDescriptor( IScanner.__CPLUSPLUS, "1")); //$NON-NLS-1$ if( scannerData.getScanner().getDefinition(IScanner.__STDC_HOSTED__) == null ) scannerData.getScanner().addDefinition(IScanner.__STDC_HOSTED__, new ObjectMacroDescriptor( IScanner.__STDC_HOSTED__, "0")); //$NON-NLS-1$ if( scannerData.getScanner().getDefinition( IScanner.__STDC_VERSION__) == null ) scannerData.getScanner().addDefinition( IScanner.__STDC_VERSION__, new ObjectMacroDescriptor( IScanner.__STDC_VERSION__, "199001L")); //$NON-NLS-1$ //TODO - these macros should not be visible as macros in the scanner's definition list //need to make a public/private table i think if( scannerData.getScanner().getDefinition( __ATTRIBUTE__) == null ) scannerData.getScanner().addDefinition( __ATTRIBUTE__, new FunctionMacroDescriptor( __ATTRIBUTE__, simpleIdentifiersDeclSpec, EMPTY_LIST, "" )); //$NON-NLS-1$ $NON-NLS-2$ if( scannerData.getScanner().getDefinition( __DECLSPEC) == null ) scannerData.getScanner().addDefinition( __DECLSPEC, new FunctionMacroDescriptor( __ATTRIBUTE__, simpleIdentifiersDeclSpec, EMPTY_LIST, "" )); //$NON-NLS-1$ $NON-NLS-2$ setupAlternativeKeyword(scannerData, __CONST__, Keywords.CONST); setupAlternativeKeyword(scannerData, __CONST, Keywords.CONST); setupAlternativeKeyword(scannerData, __INLINE__, Keywords.INLINE); setupAlternativeKeyword(scannerData, __SIGNED__, Keywords.SIGNED); setupAlternativeKeyword(scannerData, __VOLATILE__, Keywords.VOLATILE); setupAlternativeKeyword( scannerData, __RESTRICT, Keywords.RESTRICT); setupAlternativeKeyword( scannerData, __RESTRICT__, Keywords.RESTRICT); setupAlternativeKeyword( scannerData, __TYPEOF__, GCCKeywords.TYPEOF ); if( language == ParserLanguage.CPP ) setupAlternativeKeyword( scannerData, __ASM__, Keywords.ASM ); }
6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/03144000c42a4f600f030b2c1ea190c6b70acd6f/GCCScannerExtension.java/clean/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/parser/scanner/GCCScannerExtension.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 3875, 16409, 382, 9990, 6973, 12, 45, 11338, 751, 7683, 751, 16, 6783, 3779, 2653, 13, 288, 202, 202, 2211, 18, 4923, 273, 2653, 31, 25083, 202, 430, 12, 2653, 422, 6783,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3875, 16409, 382, 9990, 6973, 12, 45, 11338, 751, 7683, 751, 16, 6783, 3779, 2653, 13, 288, 202, 202, 2211, 18, 4923, 273, 2653, 31, 25083, 202, 430, 12, 2653, 422, 6783,...
if (ic_object_instance_id == -1) {
if ("-1".equals(instanceId) ) {
public IWPropertyList getMethods(int ic_object_instance_id, IWMainApplication iwma) throws Exception { String componentKey = null; IWBundle iwb = null; //Hardcoded -1 for the top page if (ic_object_instance_id == -1) { componentKey = "com.idega.presentation.Page"; iwb = iwma.getBundle(com.idega.presentation.Page.IW_BUNDLE_IDENTIFIER); } else { ICObjectInstance icoi = ((com.idega.core.component.data.ICObjectInstanceHome) com.idega.data.IDOLookup.getHomeLegacy(ICObjectInstance.class)).findByPrimaryKeyLegacy(ic_object_instance_id); ICObject obj = icoi.getObject(); iwb = obj.getBundle(iwma); componentKey = obj.getClassName(); } return getMethods(iwb, componentKey); }
54061 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54061/5e789efa8069f0a5684374a0aa2aa84e0b02c934/IBPropertyHandler.java/buggy/src/java/com/idega/builder/business/IBPropertyHandler.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 467, 59, 1396, 682, 15429, 12, 474, 13579, 67, 1612, 67, 1336, 67, 350, 16, 467, 59, 6376, 3208, 25522, 2540, 13, 1216, 1185, 288, 202, 202, 780, 1794, 653, 273, 446, 31, 20...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 467, 59, 1396, 682, 15429, 12, 474, 13579, 67, 1612, 67, 1336, 67, 350, 16, 467, 59, 6376, 3208, 25522, 2540, 13, 1216, 1185, 288, 202, 202, 780, 1794, 653, 273, 446, 31, 20...
System.out.println("Opening file "+dir+"/"+name);
public void run() { // Now the real import stuff if(name!=null && dir!=null) { Statement stat = null; try { // fetch the large object manager LargeObjectManager lom = ((org.postgresql.Connection)db).getLargeObjectAPI(); System.out.println("Importing file"); // A temporary buffer - this can be as large as you like byte buf[] = new byte[2048]; // Open the file System.out.println("Opening file "+dir+"/"+name); FileInputStream fis = new FileInputStream(new File(dir,name)); // Gain access to large objects System.out.println("Gaining LOAPI"); // Now create the large object System.out.println("creating blob"); int oid = lom.create(); System.out.println("Opening "+oid); LargeObject blob = lom.open(oid); // Now copy the file into the object. // // Note: we dont use write(buf), as the last block is rarely the same // size as our buffer, so we have to use the amount read. System.out.println("Importing file"); int s,t=0; while((s=fis.read(buf,0,buf.length))>0) { System.out.println("Block s="+s+" t="+t);t+=s; blob.write(buf,0,s); } // Close the object System.out.println("Closing blob"); blob.close(); // Now store the entry into the table // As we are a different thread to the other window, we must use // our own thread stat = db.createStatement(); stat.executeUpdate("insert into images values ('"+name+"',"+oid+")"); db.commit(); // Finally refresh the names list, and display the current image ImageViewer.this.refreshList(); ImageViewer.this.displayImage(name); } catch(Exception ex) { label.setText(ex.toString()); } finally { // ensure the statement is closed after us try { if(stat != null) stat.close(); } catch(SQLException se) { System.err.println("closing of Statement failed"); } } } }
46597 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46597/02faee5eaa0ed93364446f5c186fa6904899dca6/ImageViewer.java/clean/src/interfaces/jdbc/example/ImageViewer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1086, 1435, 288, 5411, 368, 4494, 326, 2863, 1930, 10769, 1377, 309, 12, 529, 5, 33, 2011, 597, 1577, 5, 33, 2011, 13, 288, 202, 3406, 610, 273, 446, 31, 202, 202, 698, 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, 918, 1086, 1435, 288, 5411, 368, 4494, 326, 2863, 1930, 10769, 1377, 309, 12, 529, 5, 33, 2011, 597, 1577, 5, 33, 2011, 13, 288, 202, 3406, 610, 273, 446, 31, 202, 202, 698, 288...
assertEquals("Ross", ((Person) result.getPayload()).getFirstName()); assertEquals("Mason", ((Person) result.getPayload()).getLastName());
assertEquals("Betty", ((Person) result.getPayload()).getFirstName()); assertEquals("Rubble", ((Person) result.getPayload()).getLastName());
public void testRequestResponseComplex2() throws Exception { MuleClient client = new MuleClient(); String[] args = new String[] { "Ross", "Mason" }; UMOMessage result = client.send("glue:http://localhost:38004/mule/mycomponent3?method=addPerson", args, null); assertNotNull(result); assertTrue(result.getPayload() instanceof Person); assertEquals("Ross", ((Person) result.getPayload()).getFirstName()); assertEquals("Mason", ((Person) result.getPayload()).getLastName()); // do a receive result = client.send("glue:http://localhost:38004/mule/mycomponent3?method=getPerson", "Ross", null); assertNotNull(result); assertTrue(result.getPayload() instanceof Person); assertEquals("Ross", ((Person) result.getPayload()).getFirstName()); assertEquals("Mason", ((Person) result.getPayload()).getLastName()); }
2370 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2370/b656e0806058d87c5db05880209b51a8d57416d0/MuleSoapClientTestCase.java/buggy/tests/integration/src/test/java/org/mule/test/integration/client/MuleSoapClientTestCase.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 918, 1842, 691, 1064, 12795, 22, 1435, 1216, 1185, 565, 288, 3639, 490, 725, 1227, 1004, 273, 394, 490, 725, 1227, 5621, 3639, 514, 8526, 833, 273, 394, 514, 8526, 288, 315, 54, 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, 377, 1071, 918, 1842, 691, 1064, 12795, 22, 1435, 1216, 1185, 565, 288, 3639, 490, 725, 1227, 1004, 273, 394, 490, 725, 1227, 5621, 3639, 514, 8526, 833, 273, 394, 514, 8526, 288, 315, 54, 8...
_loop647:
_loop651:
public final void buffercopystate(AST _t) throws RecognitionException { AST buffercopystate_AST_in = (_t == ASTNULL) ? null : (AST)_t; AST __t643 = _t; AST tmp579_AST_in = (AST)_t; match(_t,BUFFERCOPY); _t = _t.getFirstChild(); AST tmp580_AST_in = (AST)_t; match(_t,RECORD_NAME); _t = _t.getNextSibling(); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case EXCEPT: { AST __t645 = _t; AST tmp581_AST_in = (AST)_t; match(_t,EXCEPT); _t = _t.getFirstChild(); { _loop647: do { if (_t==null) _t=ASTNULL; if ((_t.getType()==Field_ref)) { field(_t); _t = _retTree; } else { break _loop647; } } while (true); } _t = __t645; _t = _t.getNextSibling(); break; } case USING: { AST __t648 = _t; AST tmp582_AST_in = (AST)_t; match(_t,USING); _t = _t.getFirstChild(); { int _cnt650=0; _loop650: do { if (_t==null) _t=ASTNULL; if ((_t.getType()==Field_ref)) { field(_t); _t = _retTree; } else { if ( _cnt650>=1 ) { break _loop650; } else {throw new NoViableAltException(_t);} } _cnt650++; } while (true); } _t = __t648; _t = _t.getNextSibling(); break; } case TO: { break; } default: { throw new NoViableAltException(_t); } } } AST tmp583_AST_in = (AST)_t; match(_t,TO); _t = _t.getNextSibling(); AST tmp584_AST_in = (AST)_t; match(_t,RECORD_NAME); _t = _t.getNextSibling(); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case ASSIGN: { AST __t652 = _t; AST tmp585_AST_in = (AST)_t; match(_t,ASSIGN); _t = _t.getFirstChild(); assignment_list(_t); _t = _retTree; _t = __t652; _t = _t.getNextSibling(); break; } case EOF: case PERIOD: case NOERROR_KW: case NOLOBS: { break; } default: { throw new NoViableAltException(_t); } } } { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case NOLOBS: { AST tmp586_AST_in = (AST)_t; match(_t,NOLOBS); _t = _t.getNextSibling(); break; } case EOF: case PERIOD: case NOERROR_KW: { break; } default: { throw new NoViableAltException(_t); } } } { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case NOERROR_KW: { AST tmp587_AST_in = (AST)_t; match(_t,NOERROR_KW); _t = _t.getNextSibling(); break; } case EOF: case PERIOD: { break; } default: { throw new NoViableAltException(_t); } } } state_end(_t); _t = _retTree; _t = __t643; _t = _t.getNextSibling(); _retTree = _t; }
13952 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13952/daa15e07422d3491bbbb4d0060450c81983332a4/TreeParser03.java/clean/trunk/org.prorefactor.core/src/org/prorefactor/treeparser03/TreeParser03.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 727, 918, 1613, 22295, 1094, 340, 12, 9053, 389, 88, 13, 1216, 9539, 288, 9506, 202, 9053, 1613, 22295, 1094, 340, 67, 9053, 67, 267, 273, 261, 67, 88, 422, 9183, 8560, 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, 727, 918, 1613, 22295, 1094, 340, 12, 9053, 389, 88, 13, 1216, 9539, 288, 9506, 202, 9053, 1613, 22295, 1094, 340, 67, 9053, 67, 267, 273, 261, 67, 88, 422, 9183, 8560, 13, ...
private void showTable(Event event) { TreeItem item = (TreeItem)event.item; if (item == null) return; if( item == rootNode ) return; if ( isSchemaNode( item ) ) { populateTableList( item.getText( ), item ); return; }//TODO String tableName = Utility.getTreeItemsName( item ); String catalogName = metaDataProvider.getCatalog(); String schemaName = null; String schemaSeparator = "."; if (metaDataProvider.isSchemaSupported()) { // remove the schema name from the fully qualified name int index = -1; if ((index = tableName.lastIndexOf(schemaSeparator)) != -1) { schemaName = tableName.substring(0, index); tableName = tableName.substring( index + 1); } } if ( item.getData( ) instanceof DbObject ) { DbObject obj = (DbObject) item.getData( ); if ( obj.getType( ) == DbObject.TABLE_TYPE || obj.getType( ) == DbObject.VIEW_TYPE ) { ArrayList columnList = metaDataProvider.getColumns( catalogName, schemaName, tableName, null ); TreeItem[] items = item.getItems( ); if ( items != null ) { for ( int i = 0; i < items.length; i++ ) { items[i].dispose( ); } } Utility.createTreeItems( item, columnList, SWT.NONE, columnImage ); } else if ( obj.getType( ) == DbObject.PROCEDURE_TYPE ) { ArrayList procedureList = metaDataProvider.getAllProcedure( catalogName, schemaName, getTailoredSearchText( searchTxt.getText() ) ); TreeItem[] items = item.getItems( ); if ( items != null ) { for ( int i = 0; i < items.length; i++ ) { items[i].dispose( ); } } Utility.createTreeItems( item, procedureList, SWT.NONE, columnImage ); //expand procedure TreeItem } } else if ( item.getData( ) instanceof Procedure ) { Procedure obj = (Procedure) item.getData( ); { ArrayList columnList = metaDataProvider.getProcedureColumns( obj.getCatalog( ), schemaName, tableName, getTailoredSearchText(null) ); TreeItem[] items = item.getItems( ); if ( items != null ) { for ( int i = 0; i < items.length; i++ ) { items[i].dispose( ); } } Utility.createTreeItems( item, columnList, SWT.NONE, columnImage ); } } }
5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/8887f296b0d9adc032ae9020f3349938893f43a3/SQLDataSetEditorPage.java/buggy/data/org.eclipse.birt.report.data.oda.jdbc.ui/src/org/eclipse/birt/report/data/oda/jdbc/ui/editors/SQLDataSetEditorPage.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1875, 202, 1152, 6459, 4500, 1388, 12, 1133, 2575, 13, 1082, 202, 95, 9506, 202, 2471, 1180, 1726, 28657, 2471, 1180, 13, 2575, 18, 1726, 31, 9506, 202, 430, 12, 1726, 631, 2011, 13, 2463, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1875, 202, 1152, 6459, 4500, 1388, 12, 1133, 2575, 13, 1082, 202, 95, 9506, 202, 2471, 1180, 1726, 28657, 2471, 1180, 13, 2575, 18, 1726, 31, 9506, 202, 430, 12, 1726, 631, 2011, 13, 2463, 3...
ObjectFieldAccess ofa = _getObjectFieldAccessForField(field, context);
ObjectFieldAccess ofa = _getObjectFieldAccessForField(field, nameContext);
public Object visit(QualifiedName node) { try { return super.visit(node); } catch(ExecutionError e) { // This error is thrown only if this QualifiedName is not // a local variable or a class List ids = node.getIdentifiers(); Iterator iter = ids.iterator(); String field = ((IdentifierToken)iter.next()).image(); while (iter.hasNext()) { IdentifierToken t = (IdentifierToken)iter.next(); field += "$" + t.image(); } if (context.isDefined("this")) { // Check if it's a field or outer field if we're not in a // static context. ObjectFieldAccess ofa = _getObjectFieldAccessForField(field, context); if (ofa != null) { return ofa; } } else { // We're in a static context. StaticFieldAccess sfa = _getStaticFieldAccessForField(field, context); if (sfa != null) { return sfa; } else { // This is possibly a substring of our current context's class name. // (e.g. The user is trying to evaluate MonkeyOuter.someField and we // have to convert MonkeyOuter to MonkeyMostOuter$MonkeyOuter) // Try qualifying it. ReferenceType rt = _getReferenceTypeForField(field, context); if (rt != null) { return rt; } } } // Didn't find this field in any outer class. Throw original exception. throw e; } }
11192 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11192/ba6205cad42ae00df3c37c5cbd4625770848df66/JavaDebugInterpreter.java/buggy/drjava/src/edu/rice/cs/drjava/model/repl/JavaDebugInterpreter.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4202, 1071, 1033, 3757, 12, 12345, 756, 13, 288, 3639, 775, 288, 1850, 327, 2240, 18, 11658, 12, 2159, 1769, 3639, 289, 3639, 1044, 12, 3210, 668, 425, 13, 288, 1850, 368, 1220, 555, 353, 67...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4202, 1071, 1033, 3757, 12, 12345, 756, 13, 288, 3639, 775, 288, 1850, 327, 2240, 18, 11658, 12, 2159, 1769, 3639, 289, 3639, 1044, 12, 3210, 668, 425, 13, 288, 1850, 368, 1220, 555, 353, 67...
Driver.debug("supportsCatalogsInIndexDefinitions false");
if (Driver.logDebug) Driver.debug("supportsCatalogsInIndexDefinitions false");
public boolean supportsCatalogsInIndexDefinitions() throws SQLException { Driver.debug("supportsCatalogsInIndexDefinitions false"); return false; }
49868 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49868/3c0896638bbf35fd0d5888f8c50dae91759a8f12/DatabaseMetaData.java/buggy/org/postgresql/jdbc2/DatabaseMetaData.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 1250, 6146, 39, 21836, 382, 1016, 7130, 1435, 1216, 6483, 202, 95, 202, 202, 4668, 18, 4148, 2932, 28064, 39, 21836, 382, 1016, 7130, 629, 8863, 202, 202, 2463, 629, 31, 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, 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, 1250, 6146, 39, 21836, 382, 1016, 7130, 1435, 1216, 6483, 202, 95, 202, 202, 4668, 18, 4148, 2932, 28064, 39, 21836, 382, 1016, 7130, 629, 8863, 202, 202, 2463, 629, 31, 202, ...
int repeat = 0; if(e.getClickCount() != 1) repeat = 1;
public void mousePressed(MouseEvent e) { if (ren.VisibleActorCount() == 0) return; Lock(); rw.SetDesiredUpdateRate(5.0); lastX = e.getX(); lastY = e.getY(); ctrlPressed = (e.getModifiers() & InputEvent.CTRL_MASK) == InputEvent.CTRL_MASK ? 1:0; shiftPressed = (e.getModifiers() & InputEvent.SHIFT_MASK) == InputEvent.SHIFT_MASK ? 1:0; iren.SetEventInformationFlipY(e.getX(), e.getY(), ctrlPressed, shiftPressed, '0', 0, "0"); if ((e.getModifiers() & InputEvent.BUTTON1_MASK) == InputEvent.BUTTON1_MASK) { iren.LeftButtonPressEvent(); } else if ((e.getModifiers() & InputEvent.BUTTON2_MASK) == InputEvent.BUTTON2_MASK) { { iren.MiddleButtonPressEvent(); } } else if ((e.getModifiers() & InputEvent.BUTTON3_MASK) == InputEvent.BUTTON3_MASK) { { iren.RightButtonPressEvent(); } } UnLock(); }
46824 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46824/3cb025f5bda4a371ee4b0dde6efb9b3889e406f8/vtkCanvas.java/buggy/Wrapping/Java/vtk/vtkCanvas.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 509, 7666, 273, 374, 31, 309, 12, 73, 18, 588, 6563, 1380, 1435, 480, 404, 13, 7666, 273, 404, 31, 282, 509, 7666, 273, 374, 31, 309, 12, 73, 18, 588, 6563, 1380, 1435, 480, 404, 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, 509, 7666, 273, 374, 31, 309, 12, 73, 18, 588, 6563, 1380, 1435, 480, 404, 13, 7666, 273, 404, 31, 282, 509, 7666, 273, 374, 31, 309, 12, 73, 18, 588, 6563, 1380, 1435, 480, 404, 13...
ModuleExp.evalModule(env, ctx, comp, null);
ModuleExp.evalModule(env, ctx, comp, null, null);
public static String eval(String expr) throws Throwable { CharArrayOutPort out = new CharArrayOutPort(); InPort in = new CharArrayInPort(expr); SourceMessages messages = new SourceMessages(); Compilation comp = interp.parse(in, messages, Language.PARSE_IMMEDIATE); SourceError firstError = messages.getErrors(); if (firstError != null) return "*** syntax error - " + firstError; CallContext ctx = CallContext.getInstance(); gnu.lists.Consumer save = ctx.consumer; try { ctx.consumer = interp.getOutputConsumer(out); ModuleExp mod = comp.getModule(); mod.setName("atInteractiveLevel"); // FIXME ModuleExp.evalModule(env, ctx, comp, null); } finally { ctx.consumer = save; } String result = new String(out.toCharArray()); out.close(); return result; }
41089 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/41089/cbc785330ee7607c4cfbfbd1d8c969c630c5d5ae/TestMisc.java/buggy/gnu/xquery/testsuite/TestMisc.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 282, 1071, 760, 514, 5302, 12, 780, 3065, 13, 565, 1216, 4206, 225, 288, 565, 3703, 1076, 1182, 2617, 596, 273, 394, 3703, 1076, 1182, 2617, 5621, 565, 657, 2617, 316, 273, 394, 3703, 1076, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 514, 5302, 12, 780, 3065, 13, 565, 1216, 4206, 225, 288, 565, 3703, 1076, 1182, 2617, 596, 273, 394, 3703, 1076, 1182, 2617, 5621, 565, 657, 2617, 316, 273, 394, 3703, 1076, ...
escaped = false;
public LineContext markTokens(LineContext prevContext, TokenHandler tokenHandler, Segment line, String noWordSep) { //{{{ Set up some instance variables // this is to avoid having to pass around lots and lots of // parameters. this.tokenHandler = tokenHandler; this.line = line; lastOffset = line.offset; lineLength = line.count + line.offset; context = new LineContext(); if(prevContext == null) context.rules = getMainRuleSet(); else { context.parent = prevContext.parent; context.inRule = prevContext.inRule; context.rules = prevContext.rules; } keywords = context.rules.getKeywords(); escaped = false; //}}} //{{{ Main parser loop ParserRule rule; int terminateChar = context.rules.getTerminateChar(); boolean terminated = false;main_loop: for(pos = line.offset; pos < lineLength; pos++) { //{{{ check if we have to stop parsing if(terminateChar >= 0 && pos >= terminateChar && !terminated) { terminated = true; context = new LineContext(ParserRuleSet .getStandardRuleSet(context.rules .getDefault()),context); keywords = context.rules.getKeywords(); } //}}} //{{{ check for end of delegate if(context.parent != null) { rule = context.parent.inRule; if(rule != null && rule.end != null) { if(checkDelegateEnd()) continue main_loop; } } //}}} //{{{ check every rule char ch = line.array[pos]; rule = context.rules.getRules(ch); while(rule != null) { // stop checking rules if there was a match if (handleRule(rule,false)) continue main_loop; rule = rule.next; } //}}} //{{{ check if current character is a word separator if(Character.isWhitespace(ch)) { handleSoftSpan(); if(keywords != null) markKeyword(false); if(lastOffset != pos) { tokenHandler.handleToken( context.rules.getDefault(), lastOffset - line.offset, pos - lastOffset, context); } tokenHandler.handleToken( (ch == '\t' ? Token.TAB : Token.WHITESPACE),pos - line.offset,1, context); lastOffset = pos + 1; } else { String noWordSep2 = (keywords == null ? "" : keywords.getNonAlphaNumericChars()); if(!Character.isLetterOrDigit(ch) && noWordSep.indexOf(ch) == -1 && noWordSep2.indexOf(ch) == -1) { handleSoftSpan(); markKeyword(true); tokenHandler.handleToken( context.rules.getDefault(), lastOffset - line.offset,1, context); lastOffset = pos + 1; } } //}}} escaped = false; } //}}} //{{{ Mark all remaining characters pos = lineLength; handleSoftSpan(); markKeyword(true); if(context.parent != null) { rule = context.parent.inRule; if((rule != null && (context.parent.inRule.action & ParserRule.NO_LINE_BREAK) == ParserRule.NO_LINE_BREAK) || terminated) { context = context.parent; keywords = context.rules.getKeywords(); context.inRule = null; } } //}}} tokenHandler.handleToken(Token.END,pos - line.offset,0,context); return context.intern(); } //}}}
6564 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6564/cd53d47313307a5e170bdb9a93f0863b2c8d17aa/TokenMarker.java/clean/org/gjt/sp/jedit/syntax/TokenMarker.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 5377, 1042, 2267, 5157, 12, 1670, 1042, 2807, 1042, 16, 202, 202, 1345, 1503, 1147, 1503, 16, 10807, 980, 16, 202, 202, 780, 1158, 3944, 5097, 13, 202, 95, 202, 202, 759, 1218...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5377, 1042, 2267, 5157, 12, 1670, 1042, 2807, 1042, 16, 202, 202, 1345, 1503, 1147, 1503, 16, 10807, 980, 16, 202, 202, 780, 1158, 3944, 5097, 13, 202, 95, 202, 202, 759, 1218...
getOwner().markDirty(true, true);
getOwner().reLayout( );
public void run( ) { getOwner().markDirty(true, true); }
12803 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12803/ebb2f0a299e9a6818cbf61d858e1cd609f51ddfd/TableLayout.java/buggy/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/internal/ui/layout/TableLayout.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4697, 202, 482, 918, 1086, 12, 262, 9506, 202, 95, 282, 6862, 202, 588, 5541, 7675, 3355, 10785, 12, 3767, 16, 638, 1769, 9506, 202, 97, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 4697, 202, 482, 918, 1086, 12, 262, 9506, 202, 95, 282, 6862, 202, 588, 5541, 7675, 3355, 10785, 12, 3767, 16, 638, 1769, 9506, 202, 97, 2, -100, -100, -100, -100, -100, -100, -100, -100, -1...
dX, dY, itm.getFullWidth( ),
dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ) + insCA.getTop( ), lih.getWidth( ),
public void renderLegend( IPrimitiveRenderer ipr, Legend lg, Map htRenderers ) throws ChartException { if ( !lg.isVisible( ) ) // CHECK VISIBILITY { return; } renderBlock( ipr, lg, StructureSource.createLegend( lg ) ); final IDisplayServer xs = getDevice( ).getDisplayServer( ); final double dScale = getDeviceScale( ); Bounds bo = lg.getBounds( ).scaledInstance( dScale ); Size sz = null; /* --- Start bound computing --- */ // TODO Refactoring: create function double dX, dY; if ( lg.getPosition( ) != Position.INSIDE_LITERAL ) { try { sz = lg.getPreferredSize( xs, cm, rtc ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, ex ); } sz.scale( dScale ); // validate legend size, restrict within the bounds. // TODO this is requried due to the 1/3 size constraints policy in // layoutManager, // should use better solution. if ( sz.getWidth( ) > bo.getWidth( ) ) { sz.setWidth( bo.getWidth( ) ); } if ( sz.getHeight( ) > bo.getHeight( ) ) { sz.setHeight( bo.getHeight( ) ); } // USE ANCHOR IN POSITIONING THE LEGEND CLIENT AREA WITHIN THE BLOCK // SLACK SPACE dX = bo.getLeft( ) + ( bo.getWidth( ) - sz.getWidth( ) ) / 2; dY = 0; if ( lg.isSetAnchor( ) ) { int iAnchor = lg.getAnchor( ).getValue( ); // swap west/east if ( isRightToLeft( ) ) { if ( iAnchor == Anchor.EAST ) { iAnchor = Anchor.WEST; } else if ( iAnchor == Anchor.NORTH_EAST ) { iAnchor = Anchor.NORTH_WEST; } else if ( iAnchor == Anchor.SOUTH_EAST ) { iAnchor = Anchor.SOUTH_WEST; } else if ( iAnchor == Anchor.WEST ) { iAnchor = Anchor.EAST; } else if ( iAnchor == Anchor.NORTH_WEST ) { iAnchor = Anchor.NORTH_EAST; } else if ( iAnchor == Anchor.SOUTH_WEST ) { iAnchor = Anchor.SOUTH_EAST; } } switch ( iAnchor ) { case Anchor.NORTH : case Anchor.NORTH_EAST : case Anchor.NORTH_WEST : dY = bo.getTop( ); break; case Anchor.SOUTH : case Anchor.SOUTH_EAST : case Anchor.SOUTH_WEST : dY = bo.getTop( ) + bo.getHeight( ) - sz.getHeight( ); break; default : // CENTERED dY = bo.getTop( ) + ( bo.getHeight( ) - sz.getHeight( ) ) / 2; break; } switch ( iAnchor ) { case Anchor.WEST : case Anchor.NORTH_WEST : case Anchor.SOUTH_WEST : dX = bo.getLeft( ); break; case Anchor.EAST : case Anchor.SOUTH_EAST : case Anchor.NORTH_EAST : dX = bo.getLeft( ) + bo.getWidth( ) - sz.getWidth( ); break; default : // CENTERED dX = bo.getLeft( ) + ( bo.getWidth( ) - sz.getWidth( ) ) / 2; break; } } else { dX = bo.getLeft( ) + ( bo.getWidth( ) - sz.getWidth( ) ) / 2; dY = bo.getTop( ) + ( bo.getHeight( ) - sz.getHeight( ) ) / 2; } } else { // USE PREVIOUSLY COMPUTED POSITION IN THE GENERATOR FOR LEGEND // 'INSIDE' PLOT dX = bo.getLeft( ); dY = bo.getTop( ); sz = SizeImpl.create( bo.getWidth( ), bo.getHeight( ) ); } // get cached legend info. final LegendLayoutHints lilh = rtc.getLegendLayoutHints( ); // consider legend title size. Label lgTitle = lg.getTitle( ); double lgTitleWidth = 0, lgTitleHeight = 0; double yOffset = 0, xOffset = 0, wOffset = 0, hOffset = 0; final boolean bRenderLegendTitle = lgTitle != null && lgTitle.isSetVisible( ) && lgTitle.isVisible( ); int iTitlePos = Position.ABOVE; if ( bRenderLegendTitle ) { lgTitle = LabelImpl.copyInstance( lgTitle ); // handle external resource string final String sPreviousValue = lgTitle.getCaption( ).getValue( ); lgTitle.getCaption( ) .setValue( rtc.externalizedMessage( sPreviousValue ) ); if ( lilh != null ) { // use cached value Size titleSize = lilh.getTitleSize( ); lgTitleWidth = titleSize.getWidth( ); lgTitleHeight = titleSize.getHeight( ); } else { BoundingBox bb = null; try { bb = Methods.computeBox( xs, IConstants.ABOVE, lgTitle, 0, 0 ); } catch ( IllegalArgumentException uiex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, uiex ); } lgTitleWidth = bb.getWidth( ); lgTitleHeight = bb.getHeight( ); } iTitlePos = lg.getTitlePosition( ).getValue( ); // swap left/right if ( isRightToLeft( ) ) { if ( iTitlePos == Position.LEFT ) { iTitlePos = Position.RIGHT; } else if ( iTitlePos == Position.RIGHT ) { iTitlePos = Position.LEFT; } } switch ( iTitlePos ) { case Position.ABOVE : yOffset = lgTitleHeight; hOffset = -yOffset; break; case Position.BELOW : hOffset = -lgTitleHeight; break; case Position.LEFT : xOffset = lgTitleWidth; wOffset = -xOffset; break; case Position.RIGHT : wOffset = -lgTitleWidth; break; } } // RENDER THE LEGEND CLIENT AREA final ClientArea ca = lg.getClientArea( ); final Insets lgIns = lg.getInsets( ).scaledInstance( dScale ); LineAttributes lia = ca.getOutline( ); bo = BoundsImpl.create( dX, dY, sz.getWidth( ), sz.getHeight( ) ); bo = bo.adjustedInstance( lgIns ); dX = bo.getLeft( ); dY = bo.getTop( ); // Adjust bounds. bo.delta( xOffset, yOffset, wOffset, hOffset ); dX = bo.getLeft( ); dY = bo.getTop( ); /* --- End of bounds computing --- */ final double dBaseX = dX; final double dBaseY = dY; final RectangleRenderEvent rre = (RectangleRenderEvent) ( (EventObjectCache) ir ).getEventObject( StructureSource.createLegend( lg ), RectangleRenderEvent.class ); // render client area shadow. if ( ca.getShadowColor( ) != null ) { rre.setBounds( bo.translateInstance( 3, 3 ) ); rre.setBackground( ca.getShadowColor( ) ); ipr.fillRectangle( rre ); } // render client area rre.setBounds( bo ); rre.setOutline( lia ); rre.setBackground( ca.getBackground( ) ); ipr.fillRectangle( rre ); ipr.drawRectangle( rre ); lia = LineAttributesImpl.copyInstance( lia ); lia.setVisible( true ); // SEPARATOR LINES MUST BE VISIBLE LineAttributes liSep = lg.getSeparator( ) == null ? lia : lg.getSeparator( ); final SeriesDefinition[] seda = cm.getSeriesForLegend( ); // INITIALIZATION OF VARS USED IN FOLLOWING LOOPS final Orientation o = lg.getOrientation( ); final Direction d = lg.getDirection( ); final Label la = LabelImpl.create( ); la.setCaption( TextImpl.copyInstance( lg.getText( ) ) ); la.getCaption( ).setValue( "X" ); //$NON-NLS-1$ final ITextMetrics itm = xs.getTextMetrics( la ); final double maxWrappingSize = lg.getWrappingSize( ) * dScale; final double dItemHeight = itm.getFullHeight( ); final double dHorizontalSpacing = 4; final double dVerticalSpacing = 4; double dSeparatorThickness = lia.getThickness( ); Insets insCA = ca.getInsets( ).scaledInstance( dScale ); Series seBase; List al; LegendItemRenderingHints lirh; Palette pa; int iPaletteCount; EList elPaletteEntries; Fill fPaletteEntry; final boolean bPaletteByCategory = ( cm.getLegend( ) .getItemType( ) .getValue( ) == LegendItemType.CATEGORIES ); // Get available maximum block width/height. Block bl = cm.getBlock( ); Bounds boFull = bl.getBounds( ).scaledInstance( dScale ); Insets ins = bl.getInsets( ).scaledInstance( dScale ); double dMaxX = boFull.getLeft( ) + boFull.getWidth( ) - ins.getRight( ) - lgIns.getRight( ); double dMaxY = boFull.getTop( ) + boFull.getHeight( ) - ins.getBottom( ) - lgIns.getBottom( ); // Calculate if minSlice applicable. String sMinSliceLabel = null; boolean bMinSliceApplied = false; if ( lilh != null ) { // use cached value. sMinSliceLabel = lilh.getMinSliceText( ); bMinSliceApplied = lilh.isMinSliceApplied( ); } else { boolean bMinSliceDefined = false; double dMinSlice = 0; boolean bPercentageMinSlice = false; if ( cm instanceof ChartWithoutAxes ) { bMinSliceDefined = ( (ChartWithoutAxes) cm ).isSetMinSlice( ); dMinSlice = ( (ChartWithoutAxes) cm ).getMinSlice( ); bPercentageMinSlice = ( (ChartWithoutAxes) cm ).isMinSlicePercent( ); sMinSliceLabel = ( (ChartWithoutAxes) cm ).getMinSliceLabel( ); if ( sMinSliceLabel == null || sMinSliceLabel.length( ) == 0 ) { sMinSliceLabel = IConstants.UNDEFINED_STRING; } else { sMinSliceLabel = rtc.externalizedMessage( sMinSliceLabel ); } } // calculate if need an extra legend item when minSlice defined. if ( bMinSliceDefined && bPaletteByCategory && cm instanceof ChartWithoutAxes ) { if ( !( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .isEmpty( ) ) { // OK TO ASSUME THAT 1 BASE SERIES DEFINITION EXISTS SeriesDefinition sdBase = (SeriesDefinition) ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .get( 0 ); SeriesDefinition[] sdOrtho = (SeriesDefinition[]) sdBase.getSeriesDefinitions( ) .toArray( ); DataSetIterator dsiOrtho = null; double dCurrentMinSlice = 0; for ( int i = 0; i < sdOrtho.length && !bMinSliceApplied; i++ ) { try { dsiOrtho = new DataSetIterator( ( (Series) sdOrtho[i].getRunTimeSeries( ) .get( 0 ) ).getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, ex ); } // TODO Check dataset type, throw exception or ignore?. if ( bPercentageMinSlice ) { double total = 0; while ( dsiOrtho.hasNext( ) ) { Object obj = dsiOrtho.next( ); if ( obj instanceof Number ) { total += ( (Number) obj ).doubleValue( ); } } dsiOrtho.reset( ); dCurrentMinSlice = total * dMinSlice / 100d; } else { dCurrentMinSlice = dMinSlice; } while ( dsiOrtho.hasNext( ) ) { Object obj = dsiOrtho.next( ); if ( obj instanceof Number ) { double val = ( (Number) obj ).doubleValue( ); if ( val < dCurrentMinSlice ) { bMinSliceApplied = true; break; } } } } } } } // COMPUTATIONS HERE MUST BE IN SYNC WITH THE ACTUAL RENDERER if ( o.getValue( ) == Orientation.VERTICAL ) { double dXOffset = 0, dMaxW = 0; if ( bPaletteByCategory ) { SeriesDefinition sdBase = null; FormatSpecifier fs = null; if ( cm instanceof ChartWithAxes ) { // ONLY SUPPORT 1 BASE AXIS FOR NOW final Axis axPrimaryBase = ( (ChartWithAxes) cm ).getBaseAxes( )[0]; if ( axPrimaryBase.getSeriesDefinitions( ).isEmpty( ) ) { // NOTHING TO RENDER (BASE AXIS HAS NO SERIES // DEFINITIONS) return; } // OK TO ASSUME THAT 1 BASE SERIES DEFINITION EXISTS sdBase = (SeriesDefinition) axPrimaryBase.getSeriesDefinitions( ) .get( 0 ); } else if ( cm instanceof ChartWithoutAxes ) { if ( ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .isEmpty( ) ) { // NOTHING TO RENDER (BASE AXIS HAS NO SERIES // DEFINITIONS) return; } // OK TO ASSUME THAT 1 BASE SERIES DEFINITION EXISTS sdBase = (SeriesDefinition) ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .get( 0 ); } // OK TO ASSUME THAT 1 BASE RUNTIME SERIES EXISTS seBase = (Series) sdBase.getRunTimeSeries( ).get( 0 ); pa = sdBase.getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); if ( lilh != null && lilh.getLegendItemHints( ) != null ) { // use cached value LegendItemHints[] liha = lilh.getLegendItemHints( ); LegendItemHints lih; Map columnCache = searchMaxColumnWidth( liha ); for ( int i = 0; i < liha.length; i++ ) { // render each legend item. lih = liha[i]; if ( ( lih.getType( ) & IConstants.LEGEND_ENTRY ) == IConstants.LEGEND_ENTRY ) { la.getCaption( ).setValue( lih.getText( ) ); // CYCLE THROUGH THE PALETTE fPaletteEntry = (Fill) elPaletteEntries.get( lih.getCategoryIndex( ) % iPaletteCount ); lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); double columnWidth = bo.getWidth( ); Double cachedWidth = (Double) columnCache.get( lih ); if ( cachedWidth != null ) { columnWidth = cachedWidth.doubleValue( ) + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ); } renderLegendItem( ipr, lg, la, null, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ) + insCA.getTop( ), lih.getWidth( ), dItemHeight, lih.getHeight( ), 0, columnWidth, insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); } } } else { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, ex ); } if ( sdBase != null ) { fs = sdBase.getFormatSpecifier( ); } int i = 0; while ( dsiBase.hasNext( ) ) { Object obj = dsiBase.next( ); // TODO filter the not-used legend. // render legend item. dY += insCA.getTop( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, getRunTimeContext( ).getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la, maxWrappingSize ); // RECYCLED fPaletteEntry = (Fill) elPaletteEntries.get( i++ % iPaletteCount ); // CYCLE THROUGH THE PALETTE lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); if ( dY + itm.getFullHeight( ) + insCA.getBottom( ) > dMaxY ) { dXOffset += dMaxW + insCA.getLeft( ) + insCA.getRight( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing; dMaxW = 0; dY = bo.getTop( ) + insCA.getTop( ); dX = bo.getLeft( ) + dXOffset; } dMaxW = Math.max( dMaxW, itm.getFullWidth( ) ); renderLegendItem( ipr, lg, la, null, dX, dY, itm.getFullWidth( ), dItemHeight, itm.getFullHeight( ), 0, bo.getWidth( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); dY += itm.getFullHeight( ) + insCA.getBottom( ); } // render the extra MinSlice legend item if applicable. if ( bMinSliceApplied ) { dY += insCA.getTop( ); la.getCaption( ).setValue( sMinSliceLabel ); itm.reuse( la, maxWrappingSize ); // RECYCLED fPaletteEntry = (Fill) elPaletteEntries.get( dsiBase.size( ) % iPaletteCount ); // CYCLE THROUGH THE PALETTE lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); if ( dY + itm.getFullHeight( ) + insCA.getBottom( ) > dMaxY ) { dXOffset += dMaxW + insCA.getLeft( ) + insCA.getRight( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing; dMaxW = 0; dY = bo.getTop( ) + insCA.getTop( ); dX = bo.getLeft( ) + dXOffset; } dMaxW = Math.max( dMaxW, itm.getFullWidth( ) ); renderLegendItem( ipr, lg, la, null, dX, dY, itm.getFullWidth( ), dItemHeight, itm.getFullHeight( ), 0, bo.getWidth( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); dY += itm.getFullHeight( ) + insCA.getBottom( ); } } } else if ( d.getValue( ) == Direction.TOP_BOTTOM ) { if ( lilh != null && lilh.getLegendItemHints( ) != null ) { LegendItemHints[] liha = lilh.getLegendItemHints( ); LegendItemHints lih; int k = 0; Map columnCache = searchMaxColumnWidth( liha ); for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); for ( int i = 0; i < al.size( ); i++ ) { seBase = (Series) al.get( i ); if ( !seBase.isVisible( ) ) { continue; } lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); lih = liha[k++]; if ( lih.getType( ) == IConstants.LEGEND_ENTRY ) { la.getCaption( ).setValue( lih.getText( ) ); Label valueLa = null; if ( lg.isShowValue( ) ) { valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ) .setValue( lih.getExtraText( ) ); } // CYCLE THROUGH THE PALETTE fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); double columnWidth = bo.getWidth( ); Double cachedWidth = (Double) columnCache.get( lih ); if ( cachedWidth != null ) { columnWidth = cachedWidth.doubleValue( ) + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ); } renderLegendItem( ipr, lg, la, valueLa, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ) + insCA.getTop( ), lih.getWidth( ), dItemHeight, lih.getHeight( ), lih.getExtraHeight( ), columnWidth, insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); } } if ( j < seda.length - 1 && k < liha.length ) { lih = liha[k]; if ( lih.getType( ) == IConstants.LEGEND_SEPERATOR ) { k++; renderSeparator( ipr, lg, liSep, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ), lih.getWidth( ), Orientation.HORIZONTAL_LITERAL ); } } } } else { dSeparatorThickness += dVerticalSpacing; for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { seBase = (Series) al.get( i ); lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); dY += insCA.getTop( ); Object obj = seBase.getSeriesIdentifier( ); String lgtext = rtc.externalizedMessage( String.valueOf( obj ) ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, getRunTimeContext( ).getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la, maxWrappingSize ); // RECYCLED double dFWidth = itm.getFullWidth( ); double dFHeight = itm.getFullHeight( ); Label valueLa = null; double valueHeight = 0; if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, rtc.getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ).setValue( valueText ); itm.reuse( valueLa ); dFWidth = Math.max( dFWidth, itm.getFullWidth( ) ); valueHeight = itm.getFullHeight( ); } } if ( dY + dFHeight + valueHeight + 2 + insCA.getBottom( ) > dMaxY ) { dXOffset += dMaxW + insCA.getLeft( ) + insCA.getRight( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing; dMaxW = 0; dY = bo.getTop( ) + insCA.getTop( ); dX = bo.getLeft( ) + dXOffset; } dMaxW = Math.max( dMaxW, dFWidth ); fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); // CYCLE THROUGH THE // PALETTE renderLegendItem( ipr, lg, la, valueLa, dX, dY, dFWidth, dItemHeight, dFHeight, valueHeight, bo.getWidth( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); dY += dFHeight + insCA.getBottom( ) + valueHeight + 2; } if ( j < seda.length - 1 ) { renderSeparator( ipr, lg, liSep, dX, dY + dSeparatorThickness / 2, dMaxW + insCA.getLeft( ) + insCA.getRight( ) + ( 3 * dItemHeight ) / 2, Orientation.HORIZONTAL_LITERAL ); dY += dSeparatorThickness; } } } } else if ( d.getValue( ) == Direction.LEFT_RIGHT ) { if ( lilh != null && lilh.getLegendItemHints( ) != null ) { LegendItemHints[] liha = lilh.getLegendItemHints( ); LegendItemHints lih; int k = 0; Map columnCache = searchMaxColumnWidth( liha ); for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); for ( int i = 0; i < al.size( ); i++ ) { seBase = (Series) al.get( i ); if ( !seBase.isVisible( ) ) { continue; } lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); lih = liha[k++]; if ( lih.getType( ) == IConstants.LEGEND_ENTRY ) { la.getCaption( ).setValue( lih.getText( ) ); Label valueLa = null; if ( lg.isShowValue( ) ) { valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ) .setValue( lih.getExtraText( ) ); } // CYCLE THROUGH THE PALETTE fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); double columnWidth = bo.getWidth( ); Double cachedWidth = (Double) columnCache.get( lih ); if ( cachedWidth != null ) { columnWidth = cachedWidth.doubleValue( ) + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ); } renderLegendItem( ipr, lg, la, valueLa, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ) + insCA.getTop( ), lih.getWidth( ), dItemHeight, lih.getHeight( ), lih.getExtraHeight( ), columnWidth, insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); } } if ( j < seda.length - 1 && k < liha.length ) { lih = liha[k]; if ( lih.getType( ) == IConstants.LEGEND_SEPERATOR ) { k++; renderSeparator( ipr, lg, liSep, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ), bo.getHeight( ), Orientation.VERTICAL_LITERAL ); } } } } else { dSeparatorThickness += dHorizontalSpacing; for ( int j = 0; j < seda.length; j++ ) { dMaxW = 0; al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { dY += insCA.getTop( ); seBase = (Series) al.get( i ); lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); Object obj = seBase.getSeriesIdentifier( ); String lgtext = rtc.externalizedMessage( String.valueOf( obj ) ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, getRunTimeContext( ).getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la, maxWrappingSize ); // RECYCLED double dFWidth = itm.getFullWidth( ); double dFHeight = itm.getFullHeight( ); Label valueLa = null; double valueHeight = 0; if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, rtc.getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ).setValue( valueText ); itm.reuse( valueLa ); dFWidth = Math.max( dFWidth, itm.getFullWidth( ) ); valueHeight = itm.getFullHeight( ); } } if ( dY + dFHeight + valueHeight + 2 + insCA.getBottom( ) > dMaxY ) { dXOffset += dMaxW + insCA.getLeft( ) + insCA.getRight( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing; dMaxW = 0; dY = bo.getTop( ); dX = bo.getLeft( ) + dXOffset; } dMaxW = Math.max( dMaxW, dFWidth ); fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); // CYCLE THROUGH THE // PALETTE renderLegendItem( ipr, lg, la, valueLa, dX, dY, dFWidth, dItemHeight, dFHeight, valueHeight, bo.getWidth( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); dY += dFHeight + insCA.getBottom( ) + valueHeight + 2; } // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL SPACING // + // MAX ITEM WIDTH + RIGHT INSETS dXOffset += insCA.getLeft( ) + ( 3 * dItemHeight / 2 ) + dHorizontalSpacing + dMaxW + insCA.getRight( ); dX += insCA.getLeft( ) + ( 3 * dItemHeight / 2 ) + dHorizontalSpacing + dMaxW + insCA.getRight( ); dY = bo.getTop( ); // SETUP VERTICAL SEPARATOR SPACING if ( j < seda.length - 1 ) { renderSeparator( ipr, lg, liSep, dX + dSeparatorThickness / 2, dY, bo.getHeight( ), Orientation.VERTICAL_LITERAL ); dX += dSeparatorThickness; } } } } else { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, "exception.illegal.legend.direction", //$NON-NLS-1$ new Object[]{ d.getName( ) }, Messages.getResourceBundle( rtc.getULocale( ) ) ); } } else if ( o.getValue( ) == Orientation.HORIZONTAL ) { double dYOffset = 0, dMaxH = 0; if ( bPaletteByCategory ) { SeriesDefinition sdBase = null; FormatSpecifier fs = null; if ( cm instanceof ChartWithAxes ) { // ONLY SUPPORT 1 BASE AXIS FOR NOW final Axis axPrimaryBase = ( (ChartWithAxes) cm ).getBaseAxes( )[0]; if ( axPrimaryBase.getSeriesDefinitions( ).isEmpty( ) ) { // NOTHING TO RENDER (BASE AXIS HAS NO SERIES // DEFINITIONS) return; } // OK TO ASSUME THAT 1 BASE SERIES DEFINITION EXISTS sdBase = (SeriesDefinition) axPrimaryBase.getSeriesDefinitions( ) .get( 0 ); } else if ( cm instanceof ChartWithoutAxes ) { if ( ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .isEmpty( ) ) { // NOTHING TO RENDER (BASE AXIS HAS NO SERIES // DEFINITIONS) return; } // OK TO ASSUME THAT 1 BASE SERIES DEFINITION EXISTS sdBase = (SeriesDefinition) ( (ChartWithoutAxes) cm ).getSeriesDefinitions( ) .get( 0 ); } // OK TO ASSUME THAT 1 BASE RUNTIME SERIES EXISTS seBase = (Series) sdBase.getRunTimeSeries( ).get( 0 ); pa = sdBase.getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); if ( lilh != null && lilh.getLegendItemHints( ) != null ) { // use cached value LegendItemHints[] liha = lilh.getLegendItemHints( ); LegendItemHints lih; for ( int i = 0; i < liha.length; i++ ) { // render each legend item. lih = liha[i]; if ( ( lih.getType( ) & IConstants.LEGEND_ENTRY ) == IConstants.LEGEND_ENTRY ) { la.getCaption( ).setValue( lih.getText( ) ); // CYCLE THROUGH THE PALETTE fPaletteEntry = (Fill) elPaletteEntries.get( lih.getCategoryIndex( ) % iPaletteCount ); lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); renderLegendItem( ipr, lg, la, null, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ) + insCA.getTop( ), lih.getWidth( ), dItemHeight, lih.getHeight( ), 0, lih.getWidth( ) + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); } } } else { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, ex ); } if ( sdBase != null ) { fs = sdBase.getFormatSpecifier( ); } int i = 0; double dFullWidth = 0; dY += insCA.getTop( ); while ( dsiBase.hasNext( ) ) { Object obj = dsiBase.next( ); // TODO filter the not-used legend. dX += insCA.getLeft( ); String lgtext = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, getRunTimeContext( ).getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la, maxWrappingSize ); // RECYCLED fPaletteEntry = (Fill) elPaletteEntries.get( i++ % iPaletteCount ); // CYCLE THROUGH THE PALETTE lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); dFullWidth = itm.getFullWidth( ); if ( dX + dFullWidth + ( 3 * dItemHeight ) / 2 + insCA.getRight( ) > dMaxX ) { dYOffset += dMaxH + insCA.getTop( ) + insCA.getBottom( ) + dVerticalSpacing; dMaxH = 0; dX = bo.getLeft( ) + insCA.getLeft( ); dY = bo.getTop( ) + insCA.getTop( ) + dYOffset; } dMaxH = Math.max( dMaxH, itm.getFullHeight( ) ); renderLegendItem( ipr, lg, la, null, dX, dY, dFullWidth, dItemHeight, itm.getFullHeight( ), 0, dFullWidth + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); dX += dFullWidth + ( 3 * dItemHeight ) / 2 + insCA.getRight( ); } // render the extra MinSlice legend item if applicable. if ( bMinSliceApplied ) { dX += insCA.getLeft( ); la.getCaption( ).setValue( sMinSliceLabel ); itm.reuse( la, maxWrappingSize ); // RECYCLED fPaletteEntry = (Fill) elPaletteEntries.get( dsiBase.size( ) % iPaletteCount ); // CYCLE THROUGH THE PALETTE lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); dFullWidth = itm.getFullWidth( ); if ( dX + dFullWidth + ( 3 * dItemHeight ) / 2 + insCA.getRight( ) > dMaxX ) { dYOffset += dMaxH + insCA.getTop( ) + insCA.getBottom( ) + dVerticalSpacing; dMaxH = 0; dX = bo.getLeft( ) + insCA.getLeft( ); dY = bo.getTop( ) + insCA.getTop( ) + dYOffset; } dMaxH = Math.max( dMaxH, itm.getFullHeight( ) ); renderLegendItem( ipr, lg, la, null, dX, dY, dFullWidth, dItemHeight, itm.getFullHeight( ), 0, dFullWidth + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL SPACING // + MAX ITEM WIDTH + RIGHT INSETS dX += dFullWidth + ( 3 * dItemHeight ) / 2 + insCA.getRight( ); } } } else if ( d.getValue( ) == Direction.TOP_BOTTOM ) { if ( lilh != null && lilh.getLegendItemHints( ) != null ) { LegendItemHints[] liha = lilh.getLegendItemHints( ); LegendItemHints lih; int k = 0; for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); for ( int i = 0; i < al.size( ); i++ ) { seBase = (Series) al.get( i ); if ( !seBase.isVisible( ) ) { continue; } lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); lih = liha[k++]; if ( lih.getType( ) == IConstants.LEGEND_ENTRY ) { la.getCaption( ).setValue( lih.getText( ) ); Label valueLa = null; if ( lg.isShowValue( ) ) { valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ) .setValue( lih.getExtraText( ) ); } // CYCLE THROUGH THE PALETTE fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); renderLegendItem( ipr, lg, la, valueLa, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ) + insCA.getTop( ), lih.getWidth( ), dItemHeight, lih.getHeight( ), lih.getExtraHeight( ), lih.getWidth( ) + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); } } if ( j < seda.length - 1 && k < liha.length ) { lih = liha[k]; if ( lih.getType( ) == IConstants.LEGEND_SEPERATOR ) { k++; renderSeparator( ipr, lg, liSep, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ), bo.getWidth( ), Orientation.HORIZONTAL_LITERAL ); } } } } else { dSeparatorThickness += dVerticalSpacing; for ( int j = 0; j < seda.length; j++ ) { dMaxH = 0; dY += insCA.getTop( ); dX = bo.getLeft( ) + insCA.getLeft( ); al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { seBase = (Series) al.get( i ); lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); Object obj = seBase.getSeriesIdentifier( ); String lgtext = rtc.externalizedMessage( String.valueOf( obj ) ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, getRunTimeContext( ).getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la, maxWrappingSize ); // RECYCLED double dFWidth = itm.getFullWidth( ); double dFHeight = itm.getFullHeight( ); Label valueLa = null; double valueHeight = 0; if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, rtc.getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ).setValue( valueText ); itm.reuse( valueLa ); dFWidth = Math.max( dFWidth, itm.getFullWidth( ) ); valueHeight = itm.getFullHeight( ); } } if ( dX + insCA.getLeft( ) + dFWidth + ( 3 * dItemHeight ) / 2 + insCA.getRight( ) > dMaxX ) { dYOffset += dMaxH + insCA.getTop( ) + insCA.getBottom( ) + dVerticalSpacing; dMaxH = 0; dX = bo.getLeft( ) + insCA.getLeft( ); dY = bo.getTop( ) + insCA.getTop( ) + dYOffset; } dMaxH = Math.max( dMaxH, dFHeight + valueHeight + 2 ); fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); // CYCLE THROUGH THE // PALETTE renderLegendItem( ipr, lg, la, valueLa, dX, dY, dFWidth, dItemHeight, dFHeight, valueHeight, dFWidth + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL // SPACING // + MAX ITEM WIDTH + RIGHT INSETS dX += insCA.getLeft( ) + ( 3 * dItemHeight ) / 2 + dFWidth + insCA.getRight( ); } dYOffset += insCA.getTop( ) + insCA.getBottom( ) + dMaxH + dVerticalSpacing; dY += insCA.getTop( ) + insCA.getBottom( ) + dMaxH + dVerticalSpacing; dX = bo.getLeft( ) + insCA.getLeft( ); // SETUP HORIZONTAL SEPARATOR SPACING if ( j < seda.length - 1 ) { renderSeparator( ipr, lg, liSep, dX, dY + dSeparatorThickness / 2, bo.getWidth( ), Orientation.HORIZONTAL_LITERAL ); dY += dSeparatorThickness; } } } } else if ( d.getValue( ) == Direction.LEFT_RIGHT ) { if ( lilh != null && lilh.getLegendItemHints( ) != null ) { LegendItemHints[] liha = lilh.getLegendItemHints( ); LegendItemHints lih; int k = 0; for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); for ( int i = 0; i < al.size( ); i++ ) { seBase = (Series) al.get( i ); if ( !seBase.isVisible( ) ) { continue; } lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); lih = liha[k++]; if ( lih.getType( ) == IConstants.LEGEND_ENTRY ) { la.getCaption( ).setValue( lih.getText( ) ); Label valueLa = null; if ( lg.isShowValue( ) ) { valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ) .setValue( lih.getExtraText( ) ); } // CYCLE THROUGH THE PALETTE fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); renderLegendItem( ipr, lg, la, valueLa, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ) + insCA.getTop( ), lih.getWidth( ), dItemHeight, lih.getHeight( ), lih.getExtraHeight( ), lih.getWidth( ) + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); } } if ( j < seda.length - 1 && k < liha.length ) { lih = liha[k]; if ( lih.getType( ) == IConstants.LEGEND_SEPERATOR ) { k++; renderSeparator( ipr, lg, liSep, dBaseX + lih.getLeft( ), dBaseY + lih.getTop( ), lih.getHeight( ), Orientation.VERTICAL_LITERAL ); } } } } else { dSeparatorThickness += dHorizontalSpacing; dX += insCA.getLeft( ); dY += insCA.getTop( ); for ( int j = 0; j < seda.length; j++ ) { al = seda[j].getRunTimeSeries( ); pa = seda[j].getSeriesPalette( ); elPaletteEntries = pa.getEntries( ); iPaletteCount = elPaletteEntries.size( ); FormatSpecifier fs = seda[j].getFormatSpecifier( ); for ( int i = 0; i < al.size( ); i++ ) { seBase = (Series) al.get( i ); lirh = (LegendItemRenderingHints) htRenderers.get( seBase ); Object obj = seBase.getSeriesIdentifier( ); String lgtext = rtc.externalizedMessage( String.valueOf( obj ) ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, getRunTimeContext( ).getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } la.getCaption( ).setValue( lgtext ); itm.reuse( la, maxWrappingSize ); // RECYCLED double dFWidth = itm.getFullWidth( ); double dFHeight = itm.getFullHeight( ); Label valueLa = null; double valueHeight = 0; if ( lg.isShowValue( ) ) { DataSetIterator dsiBase = null; try { dsiBase = new DataSetIterator( seBase.getDataSet( ) ); } catch ( Exception ex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, ex ); } // Use first value for each series. if ( dsiBase.hasNext( ) ) { obj = dsiBase.next( ); String valueText = String.valueOf( obj ); if ( fs != null ) { try { lgtext = ValueFormatter.format( obj, fs, rtc.getULocale( ), null ); } catch ( ChartException e ) { // ignore, use original text. } } valueLa = LabelImpl.copyInstance( seBase.getLabel( ) ); valueLa.getCaption( ).setValue( valueText ); itm.reuse( valueLa ); dFWidth = Math.max( dFWidth, itm.getFullWidth( ) ); valueHeight = itm.getFullHeight( ); } } if ( dX + insCA.getLeft( ) + dFWidth + ( 3 * dItemHeight ) / 2 + insCA.getRight( ) > dMaxX ) { dYOffset += dMaxH + insCA.getTop( ) + insCA.getBottom( ) + dVerticalSpacing; dMaxH = 0; dX = bo.getLeft( ) + insCA.getLeft( ); dY = bo.getTop( ) + dYOffset; } dMaxH = Math.max( dMaxH, dFHeight + valueHeight + 2 ); fPaletteEntry = (Fill) elPaletteEntries.get( i % iPaletteCount ); // CYCLE THROUGH THE // PALETTE renderLegendItem( ipr, lg, la, valueLa, dX, dY, dFWidth, dItemHeight, dFHeight, valueHeight, dFWidth + 3 * dItemHeight / 2 + 2 * insCA.getLeft( ), insCA.getLeft( ), dHorizontalSpacing, seBase, fPaletteEntry, lirh, i ); // LEFT INSETS + LEGEND ITEM WIDTH + HORIZONTAL // SPACING // + MAX ITEM WIDTH + RIGHT INSETS dX += insCA.getLeft( ) + ( 3 * dItemHeight ) / 2 + dHorizontalSpacing + dFWidth + insCA.getRight( ); } // SETUP VERTICAL SEPARATOR SPACING if ( j < seda.length - 1 ) { renderSeparator( ipr, lg, liSep, dX + dSeparatorThickness / 2, dY, dMaxH, Orientation.VERTICAL_LITERAL ); dX += dSeparatorThickness; } } } } else { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, "exception.illegal.legend.direction", //$NON-NLS-1$ new Object[]{ d.getName( ) }, Messages.getResourceBundle( rtc.getULocale( ) ) ); } } else { throw new ChartException( ChartEnginePlugin.ID, ChartException.RENDERING, "exception.illegal.legend.orientation", //$NON-NLS-1$ new Object[]{ o.getName( ) }, Messages.getResourceBundle( rtc.getULocale( ) ) ); } // Render legend title if defined. if ( bRenderLegendTitle ) { double lX = bo.getLeft( ); double lY = bo.getTop( ); switch ( iTitlePos ) { case Position.ABOVE : lX = bo.getLeft( ) + ( bo.getWidth( ) - lgTitleWidth ) / 2d; lY = bo.getTop( ) - lgTitleHeight; break; case Position.BELOW : lX = bo.getLeft( ) + ( bo.getWidth( ) - lgTitleWidth ) / 2d; lY = bo.getTop( ) + bo.getHeight( ); break; case Position.LEFT : lX = bo.getLeft( ) - lgTitleWidth; lY = bo.getTop( ) + ( bo.getHeight( ) - lgTitleHeight ) / 2d; break; case Position.RIGHT : lX = bo.getLeft( ) + bo.getWidth( ); lY = bo.getTop( ) + ( bo.getHeight( ) - lgTitleHeight ) / 2d; break; } final TextRenderEvent tre = (TextRenderEvent) ( (EventObjectCache) ir ).getEventObject( WrappedStructureSource.createLegendTitle( lg, lgTitle ), TextRenderEvent.class ); tre.setBlockBounds( BoundsImpl.create( lX, lY, lgTitleWidth, lgTitleHeight ) ); TextAlignment ta = TextAlignmentImpl.create( ); ta.setHorizontalAlignment( HorizontalAlignment.CENTER_LITERAL ); ta.setVerticalAlignment( VerticalAlignment.CENTER_LITERAL ); tre.setBlockAlignment( ta ); tre.setLabel( lgTitle ); tre.setAction( TextRenderEvent.RENDER_TEXT_IN_BLOCK ); ipr.drawText( tre ); } itm.dispose( ); // DISPOSE RESOURCES AFTER USE }
15160 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/15160/bdbe857d641e2e27600409e7bb20f1950ed1536b/BaseRenderer.java/buggy/chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/render/BaseRenderer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 225, 202, 482, 918, 1743, 16812, 12, 467, 9840, 6747, 277, 683, 16, 17167, 409, 15266, 16, 1635, 14049, 3420, 414, 262, 1082, 202, 15069, 14804, 503, 202, 95, 202, 202, 430, 261, 401, 23623, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1743, 16812, 12, 467, 9840, 6747, 277, 683, 16, 17167, 409, 15266, 16, 1635, 14049, 3420, 414, 262, 1082, 202, 15069, 14804, 503, 202, 95, 202, 202, 430, 261, 401, 23623, ...
asm.emitMOVZX_Reg_RegIdx_Byte(T0, T0, S0, asm.BYTE, NO_SLOT);
asm.emitMOVZX_Reg_RegIdx_Byte(T0, T0, S0, VM_Assembler.BYTE, NO_SLOT);
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, NO_SLOT); // 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, NO_SLOT); // 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, NO_SLOT); // 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, ONE_SLOT); // pushes [T0+S0+4] asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, NO_SLOT); // 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, NO_SLOT, 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, NO_SLOT, 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, NO_SLOT, 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, ONE_SLOT); // value high asm.emitMOV_Reg_RegInd (S0, SP); // offset asm.emitMOV_Reg_RegDisp(T1, SP, THREE_SLOTS); // base asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, NO_SLOT, T0); // [T1+S0] <- T0 asm.emitMOV_Reg_RegDisp(T0, SP, TWO_SLOTS); // value low asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, ONE_SLOT, 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) { Offset offset = VM_Entrypoints.saveThreadStateInstructionsField.getOffset(); genParameterRegisterLoad(1); // pass 1 parameter word asm.emitCALL_RegDisp(JTOC, offset); return true; } if (methodName == VM_MagicNames.threadSwitch) { Offset offset = VM_Entrypoints.threadSwitchInstructionsField.getOffset(); genParameterRegisterLoad(2); // pass 2 parameter words asm.emitCALL_RegDisp(JTOC, offset); return true; } if (methodName == VM_MagicNames.restoreHardwareExceptionState) { Offset offset = VM_Entrypoints.restoreHardwareExceptionStateInstructionsField.getOffset(); 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(); Offset offsetToJavaArg = THREE_SLOTS; // 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.add(4)); asm.emitPUSH_RegDisp(SP, offsetToJavaArg.add(4)); offsetToJavaArg = offsetToJavaArg.add(16); paramBytes += 8; } else { asm.emitPUSH_RegDisp(SP, offsetToJavaArg); offsetToJavaArg = offsetToJavaArg.add(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.getOffset()); asm.emitCALL_RegDisp(S0, ip.getOffset()); // (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(NO_SLOT)); asm.emitPUSH_Reg (S0); return true; } if (methodName == VM_MagicNames.getCallerFramePointer) { asm.emitPOP_Reg(T0); // Callee FP asm.emitPUSH_RegDisp(T0, Offset.fromIntSignExtend(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, Offset.fromIntSignExtend(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, Offset.fromIntSignExtend(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, Offset.fromIntSignExtend(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, NO_SLOT); // 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, NO_SLOT); // 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, NO_SLOT); // 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, NO_SLOT, 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, NO_SLOT, 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, NO_SLOT, 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, ONE_SLOT); // pushes [T0+S0+4] asm.emitPUSH_RegIdx(T0, S0, asm.BYTE, NO_SLOT); // 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, TWO_SLOTS ); // offset asm.emitMOV_Reg_RegDisp(T1, SP, THREE_SLOTS); // obj ref asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, NO_SLOT, T0); // [T1+S0] <- T0 asm.emitMOV_Reg_RegDisp(T0, SP, ONE_SLOT ); // value low asm.emitMOV_RegIdx_Reg (T1, S0, asm.BYTE, ONE_SLOT, 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, Offset.fromIntZeroExtend(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()); 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) { Offset offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffset(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); return true; } if (methodName == VM_MagicNames.invokeMethodReturningInt) { Offset offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffset(); genParameterRegisterLoad(4); // pass 4 parameter words asm.emitCALL_RegDisp(JTOC, offset); asm.emitPUSH_Reg(T0); return true; } if (methodName == VM_MagicNames.invokeMethodReturningLong) { Offset offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffset(); 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) { Offset offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffset(); 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) { Offset offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffset(); 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) { Offset offset = VM_Entrypoints.reflectiveMethodInvokerInstructionsField.getOffset(); 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(NO_SLOT).toInt() - 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.getOffset()); // 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.getOffset()); // 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.getOffset()); // 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.getOffset(), 0x00000c00); // Now store the result back into the FPU Control Word asm.emitFLDCW_RegDisp(JTOC,VM_Entrypoints.FPUControlWordField.getOffset()); 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/35bd01b7529801989a0cf74ba4bc2553fd6572ec/VM_Compiler.java/buggy/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, ...
public TableRenderer(ColumnMetaData[] meta, PrintStream out) { this(meta, out, "|");
public TableRenderer(ColumnMetaData[] meta, PrintStream out, String separator) { this.meta = meta; this.out = out; /* * we cache the rows in order to dynamically determine the * output width of each column. */ this.cacheRows = new ArrayList( MAX_CACHE_ELEMENTS ); this.alreadyFlushed = false; this.writtenRows = 0; this.colSeparator = " " + separator; this.separatorWidth = separator.length();
public TableRenderer(ColumnMetaData[] meta, PrintStream out) { this(meta, out, "|"); }
9659 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9659/78f0dfe67ad38b25fcc7a30cb3baadd66bf67de1/TableRenderer.java/buggy/src/henplus/util/TableRenderer.java
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 377, 1071, 3555, 6747, 12, 1494, 6998, 8526, 2191, 16, 21677, 596, 13, 288, 3639, 333, 12, 3901, 16, 596, 16, 11747, 8863, 565, 289, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3555, 6747, 12, 1494, 6998, 8526, 2191, 16, 21677, 596, 13, 288, 3639, 333, 12, 3901, 16, 596, 16, 11747, 8863, 565, 289, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...