rem stringlengths 1 226k | add stringlengths 0 227k | context stringlengths 6 326k | meta stringlengths 143 403 | input_ids listlengths 256 256 | attention_mask listlengths 256 256 | labels listlengths 128 128 |
|---|---|---|---|---|---|---|
+ " \"http: | + " \"/static/xhtml11.dtd\">\n" | public void makeTopHead(StringBuffer buf) { buf.append("<!DOCTYPE\n" + " html PUBLIC \"-//W3C//DTD XHTML 1.1//EN\"\n" + " \"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd\">\n" + "<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"en\">\n" + "<head>\n" + "<meta http-equiv=\"Content-Type\" content=\"text/html;\" />\n" + "<link rel=\"stylesheet\" href=\"/static/themes/"+theme+"/theme.css\" type=\"text/css\" />\n"); } | 50287 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50287/f707c58085b7dd4d2327dd6fe1ada800c27fbf0c/PageMaker.java/buggy/src/freenet/clients/http/PageMaker.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1221,
3401,
1414,
12,
780,
1892,
1681,
13,
288,
202,
202,
4385,
18,
6923,
2932,
5586,
29824,
64,
82,
6,
9506,
202,
15,
315,
202,
2620,
17187,
1239,
17,
759,
59,
23,
39,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1221,
3401,
1414,
12,
780,
1892,
1681,
13,
288,
202,
202,
4385,
18,
6923,
2932,
5586,
29824,
64,
82,
6,
9506,
202,
15,
315,
202,
2620,
17187,
1239,
17,
759,
59,
23,
39,... |
paths = new HashSet<Pair<String, String>>(); | paths = new HashSet<CompiledClass>(); | private void putName(String sourceFileName, String relativePathToSource, String pathToClass) { if (LOG.isDebugEnabled()) { LOG.debug("Registering [sourceFileName, relativePathToSource, pathToClass] = [" + sourceFileName + "; " + relativePathToSource + "; " + pathToClass + "]"); } Set<Pair<String, String>> paths = myFileNameToSourceMap.get(sourceFileName); if (paths == null) { paths = new HashSet<Pair<String, String>>(); myFileNameToSourceMap.put(sourceFileName, paths); } paths.add(new Pair<String, String>(pathToClass, relativePathToSource)); } | 56627 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56627/96b6561f780ad83b42dda927dc5252f453e88954/BackendCompilerWrapper.java/buggy/compiler/impl/com/intellij/compiler/impl/javaCompiler/BackendCompilerWrapper.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
918,
1378,
461,
12,
780,
1084,
4771,
16,
514,
12820,
774,
1830,
16,
514,
12221,
797,
13,
288,
565,
309,
261,
4842,
18,
291,
2829,
1526,
10756,
288,
1377,
2018,
18,
4148,
2932,
399... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
918,
1378,
461,
12,
780,
1084,
4771,
16,
514,
12820,
774,
1830,
16,
514,
12221,
797,
13,
288,
565,
309,
261,
4842,
18,
291,
2829,
1526,
10756,
288,
1377,
2018,
18,
4148,
2932,
399... |
super.addAtom(syma); | result.addAtom(syma); | public Crystal getP1Cell() { Crystal result = (Crystal)this.clone(); if ("P 2_1 2_1 2_1".equals(spaceGroup)) { for (int i =0; i < this.getAtomCount(); i++) { Atom a = this.getAtomAt(i); /* symmetry operations: identity (skipped) : x y z -x+0.5 -y z+0.5 I -x y+0.5 -z+0.5 II x+0.5 -y+0.5 -z III */ // do not take into account moving into unit cell Point3d point = a.getPoint3D(); if (point != null) { // point I Point3d newPoint = new Point3d(); newPoint.x = -1.0*point.x + 0.5*(ax + bx + cx); newPoint.y = -1.0*point.y; newPoint.z = point.z + 0.5*(az + bz + cz); Atom syma = (Atom)a.clone(); syma.setPoint3D(newPoint); super.addAtom(syma); // point II newPoint.x = -1.0*point.x + 0.5*(ax + bx + cx); newPoint.y = -1.0*point.y; newPoint.z = point.z + 0.5*(az + bz + cz); syma = (Atom)a.clone(); syma.setPoint3D(newPoint); super.addAtom(syma); // point III newPoint.x = -1.0*point.x + 0.5*(ax + bx + cx); newPoint.y = -1.0*point.y; newPoint.z = point.z + 0.5*(az + bz + cz); syma = (Atom)a.clone(); syma.setPoint3D(newPoint); super.addAtom(syma); } else { System.err.println("WARN: Did not copy 3D coordinates!"); } } } else { // assume P1 } return result; } | 46046 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46046/3959a99bc86859a89be7ce60bc55040f7212e984/Crystal.java/buggy/src/org/openscience/cdk/Crystal.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
14998,
31365,
1689,
21,
4020,
1435,
288,
3639,
14998,
31365,
563,
273,
261,
12893,
31365,
13,
2211,
18,
14056,
5621,
3639,
309,
7566,
52,
576,
67,
21,
576,
67,
21,
576,
67,
21,
96... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
14998,
31365,
1689,
21,
4020,
1435,
288,
3639,
14998,
31365,
563,
273,
261,
12893,
31365,
13,
2211,
18,
14056,
5621,
3639,
309,
7566,
52,
576,
67,
21,
576,
67,
21,
576,
67,
21,
96... |
int pc = e.info(); int[] code = f.code(); | int pc = e.info; int[] code = f.code; | void setarga(Expdesc e, int a) { int pc = e.info(); int[] code = f.code(); code[pc] = Lua.SETARG_A(code[pc], a); } | 47685 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47685/4eb14f62d0b24765e84b36383f5ae1a5f8163910/FuncState.java/buggy/code/FuncState.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
918,
444,
3175,
69,
12,
2966,
5569,
425,
16,
509,
279,
13,
225,
288,
282,
509,
6125,
273,
425,
18,
1376,
5621,
282,
509,
8526,
981,
273,
284,
18,
710,
5621,
282,
981,
63,
2436,
65,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
918,
444,
3175,
69,
12,
2966,
5569,
425,
16,
509,
279,
13,
225,
288,
282,
509,
6125,
273,
425,
18,
1376,
5621,
282,
509,
8526,
981,
273,
284,
18,
710,
5621,
282,
981,
63,
2436,
65,
... |
dumpMap(dos, Mmap); | Mmap.dump(dos); | public void dumpResults(String dumpfilename) throws IOException { //CallGraph callgraph = CallGraph.makeCallGraph(roots, new PACallTargetMap()); CallGraph callgraph = new CachedCallGraph(new PACallGraph(this)); //CallGraph callgraph = callGraph; DataOutputStream dos; dos = new DataOutputStream(new FileOutputStream(callgraphFileName)); LoadedCallGraph.write(callgraph, dos); dos.close(); if (DUMP_DOTGRAPH) dumpCallGraphAsDot(callgraph, callgraphFileName + ".dot"); bdd.save(dumpfilename+".A", A); bdd.save(dumpfilename+".vP", vP); bdd.save(dumpfilename+".S", S); bdd.save(dumpfilename+".L", L); bdd.save(dumpfilename+".vT", vT); bdd.save(dumpfilename+".hT", hT); bdd.save(dumpfilename+".aT", aT); bdd.save(dumpfilename+".cha", cha); bdd.save(dumpfilename+".actual", actual); bdd.save(dumpfilename+".formal", formal); bdd.save(dumpfilename+".Iret", Iret); bdd.save(dumpfilename+".Mret", Mret); bdd.save(dumpfilename+".Ithr", Ithr); bdd.save(dumpfilename+".Mthr", Mthr); bdd.save(dumpfilename+".mI", mI); bdd.save(dumpfilename+".mV", mV); bdd.save(dumpfilename+".hP", hP); bdd.save(dumpfilename+".IE", IE); bdd.save(dumpfilename+".filter", filter); if (IEc != null) bdd.save(dumpfilename+".IEc", IEc); bdd.save(dumpfilename+".visited", visited); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".config")); dumpConfig(dos); dos.close(); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".Vmap")); dumpMap(dos, Vmap); dos.close(); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".Imap")); dumpMap(dos, Imap); dos.close(); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".Hmap")); dumpMap(dos, Hmap); dos.close(); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".Fmap")); dumpMap(dos, Fmap); dos.close(); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".Tmap")); dumpMap(dos, Tmap); dos.close(); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".Nmap")); dumpMap(dos, Nmap); dos.close(); dos = new DataOutputStream(new FileOutputStream(dumpfilename+".Mmap")); dumpMap(dos, Mmap); dos.close(); } | 3029 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3029/ffbd4a6ae4b48a30869e13e4b03e3522de429c51/PA.java/buggy/joeq_core/joeq/Compiler/Analysis/IPA/PA.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
4657,
3447,
12,
780,
4657,
3459,
13,
1216,
1860,
288,
7734,
368,
1477,
4137,
745,
4660,
273,
3049,
4137,
18,
6540,
1477,
4137,
12,
22078,
16,
394,
15662,
1477,
2326,
863,
10663... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
4657,
3447,
12,
780,
4657,
3459,
13,
1216,
1860,
288,
7734,
368,
1477,
4137,
745,
4660,
273,
3049,
4137,
18,
6540,
1477,
4137,
12,
22078,
16,
394,
15662,
1477,
2326,
863,
10663... |
public FieldPointcut(final String uuid, final String pattern) { if (uuid == null) throw new IllegalArgumentException("uuid can not be null"); if (pattern == null || pattern.trim().length() == 0) throw new IllegalArgumentException("pattern of pointcut can not be null or an empty string"); m_uuid = uuid; m_expression = pattern; try { m_jexlExpr = ExpressionFactory.createExpression(m_expression); } catch (Exception e) { throw new RuntimeException("could not create jexl expression from: " + m_expression); } | public FieldPointcut(final String pattern) { this(AspectWerkz.DEFAULT_SYSTEM, pattern); | public FieldPointcut(final String uuid, final String pattern) { if (uuid == null) throw new IllegalArgumentException("uuid can not be null"); if (pattern == null || pattern.trim().length() == 0) throw new IllegalArgumentException("pattern of pointcut can not be null or an empty string"); m_uuid = uuid; m_expression = pattern; try { m_jexlExpr = ExpressionFactory.createExpression(m_expression); } catch (Exception e) { throw new RuntimeException("could not create jexl expression from: " + m_expression); } } | 7954 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7954/0ad3b8b0b4c8cf5efd75d59ea014b0d7f710afd3/FieldPointcut.java/buggy/aspectwerkz/src/main/org/codehaus/aspectwerkz/pointcut/FieldPointcut.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
2286,
2148,
5150,
12,
6385,
514,
3822,
16,
7682,
727,
514,
1936,
13,
288,
3639,
309,
261,
7080,
422,
446,
13,
604,
394,
2754,
2932,
7080,
848,
486,
506,
446,
8863,
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,
1071,
2286,
2148,
5150,
12,
6385,
514,
3822,
16,
7682,
727,
514,
1936,
13,
288,
3639,
309,
261,
7080,
422,
446,
13,
604,
394,
2754,
2932,
7080,
848,
486,
506,
446,
8863,
3639,
309,
261,... |
AST tmp2226_AST_in = (AST)_t; | AST tmp2229_AST_in = (AST)_t; | public final void field_mapping_phrase(AST _t) throws RecognitionException { AST field_mapping_phrase_AST_in = (_t == ASTNULL) ? null : (AST)_t; AST __t1108 = _t; AST tmp2223_AST_in = (AST)_t; match(_t,RELATIONFIELDS); _t = _t.getFirstChild(); AST tmp2224_AST_in = (AST)_t; match(_t,LEFTPAREN); _t = _t.getNextSibling(); field(_t); _t = _retTree; AST tmp2225_AST_in = (AST)_t; match(_t,COMMA); _t = _t.getNextSibling(); field(_t); _t = _retTree; { _loop1110: do { if (_t==null) _t=ASTNULL; if ((_t.getType()==COMMA)) { AST tmp2226_AST_in = (AST)_t; match(_t,COMMA); _t = _t.getNextSibling(); field(_t); _t = _retTree; AST tmp2227_AST_in = (AST)_t; match(_t,COMMA); _t = _t.getNextSibling(); field(_t); _t = _retTree; } else { break _loop1110; } } while (true); } AST tmp2228_AST_in = (AST)_t; match(_t,RIGHTPAREN); _t = _t.getNextSibling(); _t = __t1108; _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,
652,
67,
6770,
67,
9429,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
652,
67,
6770,
67,
9429,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
652,
67,
6770,
67,
9429,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
652,
67,
6770,
67,
9429,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
... |
} catch(HttpRecoverableException e) { | } catch(HttpException e) { | protected HttpMethod execute(UMOEvent event, boolean closeConnection) throws Exception { String method = (String) event.getProperty(HttpConnector.HTTP_METHOD_PROPERTY, HttpConstants.METHOD_POST); URI uri = event.getEndpoint().getEndpointURI().getUri(); HttpMethod httpMethod = null; Object body = event.getTransformedMessage(); if (body instanceof HttpMethod) { httpMethod = (HttpMethod) body; } else if ("GET".equalsIgnoreCase(method) || body instanceof NullPayload) { httpMethod = new GetMethod(uri.toString()); } else { PostMethod postMethod = new PostMethod(uri.toString()); if (body instanceof String) { ObjectToHttpClientMethodRequest trans = new ObjectToHttpClientMethodRequest(); httpMethod = (HttpMethod) trans.transform(body.toString()); } else if (body instanceof HttpMethod) { httpMethod = (HttpMethod) body; } else { byte[] buffer = event.getTransformedMessageAsBytes(); postMethod.setRequestBody(new ByteArrayInputStream(buffer)); postMethod.setRequestContentLength(PostMethod.CONTENT_LENGTH_AUTO); httpMethod = postMethod; } } HttpConnection connection = null; try { connection = getConnection(uri); if (connection.isProxied() && connection.isSecure()) { httpMethod = new ConnectMethod(httpMethod); } httpMethod.setDoAuthentication(true); if (event.getCredentials() != null) { // Add User Creds StringBuffer header = new StringBuffer(); header.append("Basic "); String creds = event.getCredentials().getUsername() + ":" + new String(event.getCredentials().getPassword()); header.append(new BASE64Encoder().encode(creds.getBytes())); httpMethod.addRequestHeader(HttpConstants.HEADER_AUTHORIZATION, header.toString()); } try { connection.open(); httpMethod.execute(state, connection); } catch (BindException e) { //retry Thread.sleep(100); httpMethod.execute(state, connection); } catch(HttpRecoverableException e) { logger.error(e, e); } return httpMethod; } catch (Exception e) { if (httpMethod != null) httpMethod.releaseConnection(); connection.close(); throw new DispatchException(event.getMessage(), event.getEndpoint(), e); } finally { if(connection!=null && closeConnection) { connection.close(); } } } | 2370 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2370/f6371d48a43bc65f4aed8a8e939c8d4876499b21/HttpClientMessageDispatcher.java/buggy/providers/http/src/java/org/mule/providers/http/HttpClientMessageDispatcher.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
17069,
1836,
12,
2799,
51,
1133,
871,
16,
1250,
1746,
1952,
13,
1216,
1185,
565,
288,
3639,
514,
707,
273,
261,
780,
13,
871,
18,
588,
1396,
12,
2940,
7487,
18,
3693,
67,
5327,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
17069,
1836,
12,
2799,
51,
1133,
871,
16,
1250,
1746,
1952,
13,
1216,
1185,
565,
288,
3639,
514,
707,
273,
261,
780,
13,
871,
18,
588,
1396,
12,
2940,
7487,
18,
3693,
67,
5327,
... |
System.out.println(" Here's the CFG for method: "+ ir.method.name | System.out.println(" Here's the CFG for method: "+ ir.method.getName() | protected void analyze(OPT_IR ir) { if (DEBUG) { System.out.println(" Here's the CFG for method: "+ ir.method.name +"\n"+ ir.cfg); } // Step 1: Perform a DFS numbering step1(); // Check to make sure all nodes were reached checkReachability(ir); // Step 2: the heart of the algorithm step2(); // Step 3: adjust immediate dominators of nodes whoe current version of // the immediate dominators differs from the nodes with the depth-first // number of the node's semidominator. step3(); if (DEBUG) { printResults(ir); } cfg = null; // no longer need a pointer to the cfg } | 49871 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49871/b636840796d86d400a7f80ae18aa939fc2b89a95/OPT_LTDominators.java/clean/rvm/src/vm/compilers/optimizing/optimizations/control/dominators/OPT_LTDominators.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
918,
12375,
12,
15620,
67,
7937,
9482,
13,
225,
288,
565,
309,
261,
9394,
13,
288,
4202,
2332,
18,
659,
18,
8222,
2932,
282,
13743,
1807,
326,
7577,
364,
707,
30,
13773,
9482,
18,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
918,
12375,
12,
15620,
67,
7937,
9482,
13,
225,
288,
565,
309,
261,
9394,
13,
288,
4202,
2332,
18,
659,
18,
8222,
2932,
282,
13743,
1807,
326,
7577,
364,
707,
30,
13773,
9482,
18,... |
eNotify(new ENotificationImpl(this, Notification.SET, DataPackage.SERIES_GROUPING__GROUP_TYPE, oldGroupType, groupType)); | eNotify(new ENotificationImpl(this, Notification.SET, DataPackage.SERIES_GROUPING__GROUP_TYPE, oldGroupType, groupType)); | public void setGroupType(String newGroupType) { String oldGroupType = groupType; groupType = newGroupType; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, DataPackage.SERIES_GROUPING__GROUP_TYPE, oldGroupType, groupType)); } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/e5c78f0e8317166d02fa384e14c3dd7aa1796f2c/SeriesGroupingImpl.java/buggy/chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/model/data/impl/SeriesGroupingImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
444,
1114,
559,
12,
780,
394,
1114,
559,
13,
565,
288,
3639,
514,
1592,
1114,
559,
273,
1041,
559,
31,
3639,
1041,
559,
273,
394,
1114,
559,
31,
3639,
309,
261,
73,
21107,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
444,
1114,
559,
12,
780,
394,
1114,
559,
13,
565,
288,
3639,
514,
1592,
1114,
559,
273,
1041,
559,
31,
3639,
1041,
559,
273,
394,
1114,
559,
31,
3639,
309,
261,
73,
21107,
... |
boolean synPredMatched835 = false; | boolean synPredMatched2908 = false; | public final void mMODULE_NAME(boolean _createToken) throws RecognitionException, CharStreamException, TokenStreamException { int _ttype; Token _token=null; int _begin=text.length(); _ttype = MODULE_NAME; int _saveIndex; boolean synPredMatched823 = false; if (((LA(1)=='A') && (LA(2)=='R') && (LA(3)=='R'))) { int _m823 = mark(); synPredMatched823 = true; inputState.guessing++; try { { match("ARRAY"); } } catch (RecognitionException pe) { synPredMatched823 = false; } rewind(_m823); inputState.guessing--; } if ( synPredMatched823 ) { match("ARRAY"); if ( inputState.guessing==0 ) { _ttype = ARRAY_REF; } } else { boolean synPredMatched825 = false; if (((LA(1)=='S') && (LA(2)=='C') && (LA(3)=='A'))) { int _m825 = mark(); synPredMatched825 = true; inputState.guessing++; try { { match("SCALAR"); } } catch (RecognitionException pe) { synPredMatched825 = false; } rewind(_m825); inputState.guessing--; } if ( synPredMatched825 ) { match("SCALAR"); if ( inputState.guessing==0 ) { _ttype = SCALAR_REF; } } else { boolean synPredMatched827 = false; if (((LA(1)=='H') && (LA(2)=='A') && (LA(3)=='S'))) { int _m827 = mark(); synPredMatched827 = true; inputState.guessing++; try { { match("HASH"); } } catch (RecognitionException pe) { synPredMatched827 = false; } rewind(_m827); inputState.guessing--; } if ( synPredMatched827 ) { match("HASH"); if ( inputState.guessing==0 ) { _ttype = HASH_REF; } } else { boolean synPredMatched829 = false; if (((LA(1)=='C') && (LA(2)=='O') && (LA(3)=='D'))) { int _m829 = mark(); synPredMatched829 = true; inputState.guessing++; try { { match("CODE"); } } catch (RecognitionException pe) { synPredMatched829 = false; } rewind(_m829); inputState.guessing--; } if ( synPredMatched829 ) { match("CODE"); if ( inputState.guessing==0 ) { _ttype = CODE_REF; } } else { boolean synPredMatched831 = false; if (((LA(1)=='R') && (LA(2)=='E') && (LA(3)=='F'))) { int _m831 = mark(); synPredMatched831 = true; inputState.guessing++; try { { match("REF"); } } catch (RecognitionException pe) { synPredMatched831 = false; } rewind(_m831); inputState.guessing--; } if ( synPredMatched831 ) { match("REF"); if ( inputState.guessing==0 ) { _ttype = REF; } } else { boolean synPredMatched833 = false; if (((LA(1)=='F') && (LA(2)=='i') && (LA(3)=='l'))) { int _m833 = mark(); synPredMatched833 = true; inputState.guessing++; try { { match("FileHandle"); } } catch (RecognitionException pe) { synPredMatched833 = false; } rewind(_m833); inputState.guessing--; } if ( synPredMatched833 ) { match("FileHandle"); if ( inputState.guessing==0 ) { _ttype = FILE_HANDLE; } } else { boolean synPredMatched835 = false; if (((LA(1)=='f') && (LA(2)=='i') && (LA(3)=='l'))) { int _m835 = mark(); synPredMatched835 = true; inputState.guessing++; try { { match("fileno("); } } catch (RecognitionException pe) { synPredMatched835 = false; } rewind(_m835); inputState.guessing--; } if ( synPredMatched835 ) { { match("fileno("); } { int _cnt838=0; _loop838: do { if (((LA(1) >= '0' && LA(1) <= '9'))) { matchRange('0','9'); } else { if ( _cnt838>=1 ) { break _loop838; } else {throw new NoViableAltForCharException((char)LA(1), getFilename(), getLine(), getColumn());} } _cnt838++; } while (true); } match(')'); if ( inputState.guessing==0 ) { _ttype = FILE_NO; } } else if ((_tokenSet_0.member(LA(1))) && (true) && (true)) { mPURE_NAME(false); if ( inputState.guessing==0 ) { _ttype = PURE_NAME; } } else { throw new NoViableAltForCharException((char)LA(1), getFilename(), getLine(), getColumn()); } }}}}}} if ( _createToken && _token==null && _ttype!=Token.SKIP ) { _token = makeToken(_ttype); _token.setText(new String(text.getBuffer(), _begin, text.length()-_begin)); } _returnToken = _token; } | 48756 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48756/5049f6eadb6eff8f7d24ae4a36bc564cb893e02c/PerlBaseLexer.java/clean/org.epic.debug/src/org/epic/debug/varparser/PerlBaseLexer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
312,
12194,
67,
1985,
12,
6494,
389,
2640,
1345,
13,
1216,
9539,
16,
3703,
1228,
503,
16,
3155,
1228,
503,
288,
202,
202,
474,
389,
88,
723,
31,
3155,
389,
2316,
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,
202,
482,
727,
918,
312,
12194,
67,
1985,
12,
6494,
389,
2640,
1345,
13,
1216,
9539,
16,
3703,
1228,
503,
16,
3155,
1228,
503,
288,
202,
202,
474,
389,
88,
723,
31,
3155,
389,
2316,
3... |
suite.addTest(new TidyOutputBugsTest("test433666")); | public static Test suite() { TestSuite suite = new TestSuite("All the NOT working test cases for JTidy"); suite.addTest(new JTidyBugsTest("test508245")); suite.addTest(new JTidyBugsTest("test527118")); suite.addTest(new JTidyBugsTest("test791933")); suite.addTest(new JTidyBugsTest("test763191")); suite.addTest(new JTidyBugsTest("test763186")); suite.addTest(new JTidyBugsTest("test917012")); suite.addTest(new JTidyBugsTest("test922302")); suite.addTest(new JTidyBugsTest("test943559")); suite.addTest(new JTidyBugsTest("test935796")); suite.addTest(new TidyEncodingBugsTest("test647255")); suite.addTest(new TidyEncodingBugsTest("test649812")); suite.addTest(new TidyEncodingBugsTest("test658230")); suite.addTest(new TidyEncodingBugsTest("test660397")); suite.addTest(new TidyEncodingBugsTest("test676156")); suite.addTest(new TidyEncodingBugsTest("test688746")); suite.addTest(new TidyOutputBugsTest("test427633")); suite.addTest(new TidyOutputBugsTest("test427820")); suite.addTest(new TidyOutputBugsTest("test427821")); suite.addTest(new TidyOutputBugsTest("test427822")); suite.addTest(new TidyOutputBugsTest("test427823")); suite.addTest(new TidyOutputBugsTest("test427826")); suite.addTest(new TidyOutputBugsTest("test427830")); suite.addTest(new TidyOutputBugsTest("test427833")); suite.addTest(new TidyOutputBugsTest("test427836")); suite.addTest(new TidyOutputBugsTest("test427838")); suite.addTest(new TidyOutputBugsTest("test427845")); suite.addTest(new TidyOutputBugsTest("test431739")); suite.addTest(new TidyOutputBugsTest("test431958")); suite.addTest(new TidyOutputBugsTest("test433012")); suite.addTest(new TidyOutputBugsTest("test433360")); suite.addTest(new TidyOutputBugsTest("test433666")); suite.addTest(new TidyOutputBugsTest("test435903")); suite.addTest(new TidyOutputBugsTest("test435909")); suite.addTest(new TidyOutputBugsTest("test435920")); suite.addTest(new TidyOutputBugsTest("test435923")); suite.addTest(new TidyOutputBugsTest("test437468")); suite.addTest(new TidyOutputBugsTest("test438954")); suite.addTest(new TidyOutputBugsTest("test441508")); suite.addTest(new TidyOutputBugsTest("test443576")); suite.addTest(new TidyOutputBugsTest("test443678")); suite.addTest(new TidyOutputBugsTest("test445074")); suite.addTest(new TidyOutputBugsTest("test445394")); suite.addTest(new TidyOutputBugsTest("test445557")); suite.addTest(new TidyOutputBugsTest("test449348")); suite.addTest(new TidyOutputBugsTest("test467863")); suite.addTest(new TidyOutputBugsTest("test467865")); suite.addTest(new TidyOutputBugsTest("test470663")); suite.addTest(new TidyOutputBugsTest("test480701")); suite.addTest(new TidyOutputBugsTest("test480843")); suite.addTest(new TidyOutputBugsTest("test500236")); suite.addTest(new TidyOutputBugsTest("test503436")); suite.addTest(new TidyOutputBugsTest("test504206")); suite.addTest(new TidyOutputBugsTest("test505770")); suite.addTest(new TidyOutputBugsTest("test508936")); suite.addTest(new TidyOutputBugsTest("test511243")); suite.addTest(new TidyOutputBugsTest("test511679")); suite.addTest(new TidyOutputBugsTest("test514348")); suite.addTest(new TidyOutputBugsTest("test514893")); suite.addTest(new TidyOutputBugsTest("test517550")); suite.addTest(new TidyOutputBugsTest("test533105")); suite.addTest(new TidyOutputBugsTest("test533233")); suite.addTest(new TidyOutputBugsTest("test537604")); suite.addTest(new TidyOutputBugsTest("test540045")); suite.addTest(new TidyOutputBugsTest("test540555")); suite.addTest(new TidyOutputBugsTest("test540571")); suite.addTest(new TidyOutputBugsTest("test578216")); suite.addTest(new TidyOutputBugsTest("test586555")); suite.addTest(new TidyOutputBugsTest("test586562")); suite.addTest(new TidyOutputBugsTest("test593705")); suite.addTest(new TidyOutputBugsTest("test598860")); suite.addTest(new TidyOutputBugsTest("test620531")); suite.addTest(new TidyOutputBugsTest("test629885")); suite.addTest(new TidyOutputBugsTest("test640473")); suite.addTest(new TidyOutputBugsTest("test640474")); suite.addTest(new TidyOutputBugsTest("test646946")); suite.addTest(new TidyOutputBugsTest("test647900")); suite.addTest(new TidyOutputBugsTest("test655338")); suite.addTest(new TidyOutputBugsTest("test656889")); suite.addTest(new TidyOutputBugsTest("test663548")); suite.addTest(new TidyOutputBugsTest("test678268")); suite.addTest(new TidyOutputBugsTest("test680664")); suite.addTest(new TidyOutputBugsTest("test695408")); suite.addTest(new TidyOutputBugsTest("test708322")); suite.addTest(new TidyOutputBugsTest("test735603")); suite.addTest(new TidyWarningBugsTest("test433607")); suite.addTest(new TidyWarningBugsTest("test433670")); suite.addTest(new TidyWarningBugsTest("test434047")); suite.addTest(new TidyWarningBugsTest("test435922")); suite.addTest(new TidyWarningBugsTest("test446019")); suite.addTest(new TidyWarningBugsTest("test516370")); suite.addTest(new TidyWarningBugsTest("test552861")); suite.addTest(new TidyWarningBugsTest("test431964")); suite.addTest(new TidyWarningBugsTest("test501669")); suite.addTest(new TidyWarningBugsTest("test525081")); suite.addTest(new TidyWordBugsTest("test431721")); suite.addTest(new TidyWordBugsTest("test444394")); suite.addTest(new TidyWordBugsTest("test463066")); suite.addTest(new TidyWordBugsTest("test634889")); // previously working suite.addTest(new TidyOutputBugsTest("test431736")); suite.addTest(new TidyOutputBugsTest("test531964")); suite.addTest(new TidyOutputBugsTest("test996484")); return suite; } | 53077 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/53077/8922c582363f8c17be4a152f40ad9405ffdbc40d/AllNotWorkingTests.java/clean/jtidy/src/test/org/w3c/tidy/AllNotWorkingTests.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
7766,
11371,
1435,
565,
288,
3639,
7766,
13587,
11371,
273,
394,
7766,
13587,
2932,
1595,
326,
4269,
5960,
1842,
6088,
364,
804,
56,
29609,
8863,
3639,
11371,
18,
1289,
4709,
12,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
7766,
11371,
1435,
565,
288,
3639,
7766,
13587,
11371,
273,
394,
7766,
13587,
2932,
1595,
326,
4269,
5960,
1842,
6088,
364,
804,
56,
29609,
8863,
3639,
11371,
18,
1289,
4709,
12,... | |
for(ProgramPoint p : assumedNonNull.get(f)) bugReporter.reportBug(new BugInstance(this, "NP_UNWRITTEN_FIELD", | for (ProgramPoint p : assumedNonNull.get(f)) bugReporter.reportBug(new BugInstance(this, "NP_UNWRITTEN_FIELD", | public void report() { TreeSet<FieldAnnotation> notInitializedInConstructors = new TreeSet<FieldAnnotation>(declaredFields); notInitializedInConstructors.retainAll(readFields); notInitializedInConstructors.retainAll(writtenFields); notInitializedInConstructors.retainAll(assumedNonNull.keySet()); notInitializedInConstructors.removeAll(writtenInConstructorFields); TreeSet<FieldAnnotation> readOnlyFields = new TreeSet<FieldAnnotation>(declaredFields); readOnlyFields.removeAll(writtenFields); readOnlyFields.retainAll(readFields); TreeSet<FieldAnnotation> nullOnlyFields = new TreeSet<FieldAnnotation>(declaredFields); nullOnlyFields.removeAll(writtenNonNullFields); nullOnlyFields.retainAll(readFields); Set<FieldAnnotation> writeOnlyFields = declaredFields; writeOnlyFields.removeAll(readFields); for (Iterator<FieldAnnotation> i = notInitializedInConstructors.iterator(); i.hasNext();) { FieldAnnotation f = i.next(); String fieldName = f.getFieldName(); String className = f.getClassName(); String fieldSignature = f.getFieldSignature(); if (!superWrittenFields.contains(fieldName) && !fieldsOfSerializableOrNativeClassed.contains(f) && (fieldSignature.charAt(0) == 'L' || fieldSignature.charAt(0) == '[') ) { int priority = LOW_PRIORITY; bugReporter.reportBug(new BugInstance(this, "UWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTOR", priority) .addClass(className) .addField(f)); } } for (Iterator<FieldAnnotation> i = readOnlyFields.iterator(); i.hasNext();) { FieldAnnotation f = i.next(); String fieldName = f.getFieldName(); String className = f.getClassName(); String fieldSignature = f.getFieldSignature(); if (!superWrittenFields.contains(fieldName) && !fieldsOfSerializableOrNativeClassed.contains(f)) { int priority = NORMAL_PRIORITY; if (!(fieldSignature.charAt(0) == 'L' || fieldSignature.charAt(0) == '[')) priority++; bugReporter.reportBug(new BugInstance(this, "UWF_UNWRITTEN_FIELD", priority) .addClass(className) .addField(f)); } } for (Iterator<FieldAnnotation> i = nullOnlyFields.iterator(); i.hasNext();) { FieldAnnotation f = i.next(); String fieldName = f.getFieldName(); String className = f.getClassName(); String fieldSignature = f.getFieldSignature(); if (DEBUG) { System.out.println("Null only: " + f); System.out.println(" : " + assumedNonNull.containsKey(f)); } if (superWrittenFields.contains(fieldName)) continue; if (fieldsOfSerializableOrNativeClassed.contains(f)) continue; int priority = NORMAL_PRIORITY; if (assumedNonNull.containsKey(f)) { priority = HIGH_PRIORITY; for(ProgramPoint p : assumedNonNull.get(f)) bugReporter.reportBug(new BugInstance(this, "NP_UNWRITTEN_FIELD", NORMAL_PRIORITY) .addClassAndMethod(p.method) .addSourceLine(p.sourceLine) ); } if (!readOnlyFields.contains(f)) bugReporter.reportBug(new BugInstance(this, "UWF_NULL_FIELD", priority) .addClass(className) .addField(f)); } for (Iterator<FieldAnnotation> i = writeOnlyFields.iterator(); i.hasNext();) { FieldAnnotation f = i.next(); String fieldName = f.getFieldName(); String className = f.getClassName(); int lastDollar = Math.max(className.lastIndexOf('$'), className.lastIndexOf('+')); boolean isAnonymousInnerClass = (lastDollar > 0) && (lastDollar < className.length() - 1) && Character.isDigit(className.charAt(className.length() - 1)); if (DEBUG) { System.out.println("Checking write only field " + className + "." + fieldName + "\t" + superReadFields.contains(fieldName) + "\t" + constantFields.contains(f) + "\t" + f.isStatic() ); } if (superReadFields.contains(fieldName)) continue; if (dontComplainAbout.matcher(fieldName).find()) continue; if (fieldName.startsWith("this$") || fieldName.startsWith("this+")) { if (!innerClassCannotBeStatic.contains(className)) { boolean easyChange = !needsOuterObjectInConstructor.contains(className); if (easyChange || !isAnonymousInnerClass) { // easyChange isAnonymousInnerClass // true false medium, SIC // true true low, SIC_ANON // false true not reported // false false low, SIC_THIS int priority = LOW_PRIORITY; if (easyChange && !isAnonymousInnerClass) priority = NORMAL_PRIORITY; String bug = "SIC_INNER_SHOULD_BE_STATIC"; if (isAnonymousInnerClass) bug = "SIC_INNER_SHOULD_BE_STATIC_ANON"; else if (!easyChange) bug = "SIC_INNER_SHOULD_BE_STATIC_NEEDS_THIS"; bugReporter.reportBug(new BugInstance(this, bug, priority) .addClass(className)); } } } else { if (constantFields.contains(f)) { if (!f.isStatic()) bugReporter.reportBug(new BugInstance(this, "SS_SHOULD_BE_STATIC", NORMAL_PRIORITY) .addClass(className) .addField(f)); } else if (fieldsOfSerializableOrNativeClassed.contains(f)) { // ignore it } else if (!writtenFields.contains(f) && !superWrittenFields.contains(fieldName)) bugReporter.reportBug(new BugInstance(this, "UUF_UNUSED_FIELD", NORMAL_PRIORITY) .addClass(className) .addField(f)); else if (!f.isStatic() || !finalFields.contains(f)) bugReporter.reportBug(new BugInstance(this, "URF_UNREAD_FIELD", NORMAL_PRIORITY) .addClass(className) .addField(f)); } } } | 7352 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7352/6283ec82a0713e109b5a169c0a420974b6bad830/UnreadFields.java/buggy/findbugs/src/java/edu/umd/cs/findbugs/detect/UnreadFields.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
2605,
1435,
288,
202,
202,
2471,
694,
32,
974,
3257,
34,
486,
11459,
382,
29590,
273,
1082,
3639,
394,
19461,
32,
974,
3257,
34,
12,
16571,
2314,
1769,
202,
202,
902,
114... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2605,
1435,
288,
202,
202,
2471,
694,
32,
974,
3257,
34,
486,
11459,
382,
29590,
273,
1082,
3639,
394,
19461,
32,
974,
3257,
34,
12,
16571,
2314,
1769,
202,
202,
902,
114... |
attrib.cpu = "v850"; | attrib.cpu = "v850"; | public Attribute getAttributes() throws IOException { Attribute attrib = new Attribute(); switch( ehdr.e_type ) { case Elf.ELFhdr.ET_CORE: attrib.type = Attribute.ELF_TYPE_CORE; break; case Elf.ELFhdr.ET_EXEC: attrib.type = Attribute.ELF_TYPE_EXE; break; case Elf.ELFhdr.ET_REL: attrib.type = Attribute.ELF_TYPE_OBJ; break; case Elf.ELFhdr.ET_DYN: attrib.type = Attribute.ELF_TYPE_SHLIB; break; } switch (ehdr.e_machine) { case Elf.ELFhdr.EM_386 : case Elf.ELFhdr.EM_486 : attrib.cpu = "x86"; break; case Elf.ELFhdr.EM_68K: attrib.cpu = "m68k"; break; case Elf.ELFhdr.EM_PPC : case Elf.ELFhdr.EM_CYGNUS_POWERPC : case Elf.ELFhdr.EM_RS6000 : attrib.cpu = "ppc"; break; case Elf.ELFhdr.EM_PPC64 : attrib.cpu = "ppc64"; break; case Elf.ELFhdr.EM_SH : attrib.cpu = "sh"; break; case Elf.ELFhdr.EM_ARM : attrib.cpu = "arm"; break; case Elf.ELFhdr.EM_MIPS_RS3_LE : case Elf.ELFhdr.EM_MIPS : attrib.cpu = "mips"; break; case Elf.ELFhdr.EM_SPARC32PLUS: case Elf.ELFhdr.EM_SPARC: case Elf.ELFhdr.EM_SPARCV9: attrib.cpu = "sparc"; break; case Elf.ELFhdr.EM_H8_300: case Elf.ELFhdr.EM_H8_300H: attrib.cpu = "h8300"; break; case Elf.ELFhdr.EM_V850: case Elf.ELFhdr.EM_CYGNUS_V850: attrib.cpu = "v850"; break; case Elf.ELFhdr.EM_MN10300: case Elf.ELFhdr.EM_CYGNUS_MN10300: attrib.cpu = "mn10300"; break; case Elf.ELFhdr.EM_MN10200: case Elf.ELFhdr.EM_CYGNUS_MN10200: attrib.cpu = "mn10200"; break; case Elf.ELFhdr.EM_M32R: attrib.cpu = "m32r"; break; case Elf.ELFhdr.EM_FR30: case Elf.ELFhdr.EM_CYGNUS_FR30: attrib.cpu = "fr30"; break; case Elf.ELFhdr.EM_XSTORMY16: attrib.cpu = "xstormy16"; break; case Elf.ELFhdr.EM_CYGNUS_FRV: attrib.cpu = "frv"; break; case Elf.ELFhdr.EM_IQ2000: attrib.cpu = "iq2000"; break; case Elf.ELFhdr.EM_NONE: default: attrib.cpu = "none"; } switch (ehdr.e_ident[Elf.ELFhdr.EI_DATA]) { case Elf.ELFhdr.ELFDATA2LSB : attrib.isle = true; break; case Elf.ELFhdr.ELFDATA2MSB : attrib.isle = false; break; } // getSections // find .debug using toString Section [] sec = getSections(); if(sec != null) { for (int i = 0; i < sec.length; i++) { String s = sec[i].toString(); if (s.equals(".debug_info")) { attrib.debugType = Attribute.DEBUG_TYPE_DWARF; break; } else if (s.equals(".stab")) { attrib.debugType = Attribute.DEBUG_TYPE_STABS; break; } } } return attrib; } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/95f42aeb9e7f38db093795981bd7c7300a3eeeb6/Elf.java/buggy/core/org.eclipse.cdt.core/utils/org/eclipse/cdt/utils/elf/Elf.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3601,
10183,
1435,
1216,
1860,
288,
202,
202,
1499,
5885,
273,
394,
3601,
5621,
377,
202,
565,
1620,
12,
425,
16587,
18,
73,
67,
723,
262,
288,
540,
202,
3593,
10426,
74,
18,
2247... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3601,
10183,
1435,
1216,
1860,
288,
202,
202,
1499,
5885,
273,
394,
3601,
5621,
377,
202,
565,
1620,
12,
425,
16587,
18,
73,
67,
723,
262,
288,
540,
202,
3593,
10426,
74,
18,
2247... |
CreateDFACandidacyBean createDFACandidacyBean = new CreateDFACandidacyBean(); request.setAttribute("candidacyBean", createDFACandidacyBean); return mapping.findForward("chooseExecutionDegree"); | CreateDFACandidacyBean createDFACandidacyBean = new CreateDFACandidacyBean(); request.setAttribute("candidacyBean", createDFACandidacyBean); return mapping.findForward("chooseExecutionDegree"); | public ActionForward prepareCreateCandidacy(ActionMapping mapping, ActionForm actionForm, HttpServletRequest request, HttpServletResponse response) { CreateDFACandidacyBean createDFACandidacyBean = new CreateDFACandidacyBean(); request.setAttribute("candidacyBean", createDFACandidacyBean); return mapping.findForward("chooseExecutionDegree"); } | 2645 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2645/5c3dc2c3719b5088c690a493b9a51c7dbe70de86/DFACandidacyDispatchAction.java/buggy/src/net/sourceforge/fenixedu/presentationTier/Action/administrativeOffice/candidacy/DFACandidacyDispatchAction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
4382,
8514,
2911,
1684,
39,
3339,
3505,
12,
1803,
3233,
2874,
16,
4382,
1204,
1301,
1204,
16,
5411,
9984,
590,
16,
12446,
766,
13,
288,
377,
202,
1684,
40,
2046,
39,
3339,
3505,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
4382,
8514,
2911,
1684,
39,
3339,
3505,
12,
1803,
3233,
2874,
16,
4382,
1204,
1301,
1204,
16,
5411,
9984,
590,
16,
12446,
766,
13,
288,
377,
202,
1684,
40,
2046,
39,
3339,
3505,
3... |
data.metadata = encodeMetadata(meta, DEFAULT_COLOR, type, revisions).toString(); | data.metadata = encodeMetadata(meta, DEFAULT_COLOR, type, revisions).toString(); | protected static UnderlyingData prepareCreate(byte tp, int id, Folder folder, short volumeId, String name, String creator, String type, ParsedDocument pd, Document parent, Metadata meta) throws ServiceException { if (folder == null || !folder.canContain(TYPE_DOCUMENT)) throw MailServiceException.CANNOT_CONTAIN(); if (!folder.canAccess(ACL.RIGHT_INSERT)) throw ServiceException.PERM_DENIED("you do not have the required rights on the folder"); validateName(name); Mailbox mbox = folder.getMailbox(); MetadataList revisions = new MetadataList(); Metadata rev = getRevisionMetadata(mbox.getOperationChangeID(), creator, pd); rev.put(Metadata.FN_VERSION, 1); revisions.add(rev); UnderlyingData data = new UnderlyingData(); data.id = id; data.type = tp; data.folderId = folder.getId(); data.indexId = id; data.imapId = id; data.volumeId = volumeId; data.date = mbox.getOperationTimestamp(); data.size = pd.getSize(); data.name = name; data.subject = name; data.blobDigest = pd.getDigest(); data.metadata = encodeMetadata(meta, DEFAULT_COLOR, type, revisions).toString(); return data; } | 6965 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6965/4710c69ca3069efb5e7330dcad5f982a6ea62403/Document.java/clean/ZimbraServer/src/java/com/zimbra/cs/mailbox/Document.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
760,
21140,
6291,
751,
2911,
1684,
12,
7229,
8071,
16,
509,
612,
16,
12623,
3009,
16,
3025,
3940,
548,
16,
514,
508,
16,
514,
11784,
16,
514,
618,
16,
19244,
2519,
4863,
16,
4319,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
760,
21140,
6291,
751,
2911,
1684,
12,
7229,
8071,
16,
509,
612,
16,
12623,
3009,
16,
3025,
3940,
548,
16,
514,
508,
16,
514,
11784,
16,
514,
618,
16,
19244,
2519,
4863,
16,
4319,... |
public static void defaultActionText(ActionEvent e, OutlinerCellRendererImpl textArea, JoeTree tree, OutlineLayoutManager layout) { Node currentNode = textArea.node; int mod = e.getModifiers(); boolean isControlDown = (mod & ActionEvent.CTRL_MASK) == ActionEvent.CTRL_MASK; boolean isAltDown = (mod & ActionEvent.ALT_MASK) == ActionEvent.ALT_MASK; boolean isMetaDown = (mod & ActionEvent.META_MASK) == ActionEvent.META_MASK; // If we're read-only then abort if (!currentNode.isEditable()) { if (!isControlDown && !isAltDown && !isMetaDown) { Outliner.outliner.getToolkit().beep(); } return; } if (isControlDown || isAltDown || isMetaDown) { return; } // Insert char into textArea (Code taken from javax.swing.text.DefaultEditorKit.DefaultKeyTypedAction class) String content = e.getActionCommand(); if ((content != null) && (content.length() > 0) && ((mod & ActionEvent.ALT_MASK) == (mod & ActionEvent.CTRL_MASK))) { char ch = content.charAt(0); switch(ch) { case KeyEvent.VK_ENTER: case KeyEvent.VK_TAB: case KeyEvent.VK_ESCAPE: return; } if ((ch >= 0x20) && (ch != 0x7F)) { textArea.replaceSelection(content); } } // Record some Values int caretPosition = textArea.getCaretPosition(); // Update the value in the node String oldText = currentNode.getValue(); String newText = textArea.getText(); currentNode.setValue(newText); // Put the Undoable onto the UndoQueue UndoableEdit undoable = tree.getDocument().getUndoQueue().getIfEdit(); if ((undoable != null) && (undoable.getNode() == currentNode) && (!undoable.isFrozen())) { undoable.setNewText(newText); undoable.setNewPosition(caretPosition); undoable.setNewMarkPosition(caretPosition); } else { tree.getDocument().getUndoQueue().add(new UndoableEdit(currentNode, oldText, newText, tree.getCursorPosition(), caretPosition, tree.getCursorMarkPosition(), caretPosition)); } // Record the EditingNode, Mark and CursorPosition tree.setEditingNode(currentNode); tree.setCursorMarkPosition(textArea.getCaret().getMark()); tree.setCursorPosition(caretPosition, false); tree.getDocument().setPreferredCaretPosition(caretPosition); // Do the Redraw if we have wrapped or if we are currently off screen. if (textArea.getPreferredSize().height != textArea.height || !currentNode.isVisible()) { layout.draw(currentNode, OutlineLayoutManager.TEXT); } } | 49473 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49473/f2f43cdd7e14deb3d8e2f842114f3d3d52336ea9/DefaultAction.java/clean/outliner/src/com/organic/maynard/outliner/actions/DefaultAction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
918,
805,
1803,
1528,
12,
1803,
1133,
425,
16,
2976,
7511,
264,
4020,
6747,
2828,
977,
5484,
16,
804,
15548,
2471,
2151,
16,
2976,
1369,
3744,
1318,
3511,
13,
288,
3196,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
918,
805,
1803,
1528,
12,
1803,
1133,
425,
16,
2976,
7511,
264,
4020,
6747,
2828,
977,
5484,
16,
804,
15548,
2471,
2151,
16,
2976,
1369,
3744,
1318,
3511,
13,
288,
3196,
... | ||
this.blockInsertContext = ctx; this.segNo = segNo; if(!"SplitFileInserterSegment".equals(fs.get("Type"))) throw new ResumeException("Wrong Type: "+fs.get("Type")); finished = Fields.stringToBool(fs.get("Finished"), false); encoded = true; started = Fields.stringToBool(fs.get("Started"), false); SimpleFieldSet errorsFS = fs.subset("Errors"); if(errorsFS != null) this.errors = new FailureCodeTracker(true, errorsFS); else this.errors = new FailureCodeTracker(true); if(finished && !errors.isEmpty()) toThrow = InserterException.construct(errors); blocksGotURI = 0; blocksCompleted = 0; SimpleFieldSet dataFS = fs.subset("DataBlocks"); if(dataFS == null) throw new ResumeException("No data blocks"); String tmp = dataFS.get("Count"); if(tmp == null) throw new ResumeException("No data block count"); int dataBlockCount; try { dataBlockCount = Integer.parseInt(tmp); } catch (NumberFormatException e) { throw new ResumeException("Corrupt data blocks count: "+e+" : "+tmp); } hasURIs = true; dataBlocks = new Bucket[dataBlockCount]; dataURIs = new FreenetURI[dataBlockCount]; dataBlockInserters = new SingleBlockInserter[dataBlockCount]; SimpleFieldSet checkFS = fs.subset("CheckBlocks"); if(checkFS != null) { tmp = checkFS.get("Count"); if(tmp == null) throw new ResumeException("Check blocks but no check block count"); int checkBlockCount; try { checkBlockCount = Integer.parseInt(tmp); } catch (NumberFormatException e) { throw new ResumeException("Corrupt check blocks count: "+e+" : "+tmp); } checkBlocks = new Bucket[checkBlockCount]; checkURIs = new FreenetURI[checkBlockCount]; checkBlockInserters = new SingleBlockInserter[checkBlockCount]; for(int i=0;i<checkBlockCount;i++) { String index = Integer.toString(i); SimpleFieldSet blockFS = checkFS.subset(index); if(blockFS == null) { hasURIs = false; encoded = false; Logger.normal(this, "Clearing encoded because block "+i+" of "+segNo+" missing"); continue; } tmp = blockFS.get("URI"); if(tmp != null) { try { checkURIs[i] = new FreenetURI(tmp); blocksGotURI++; } catch (MalformedURLException e) { throw new ResumeException("Corrupt URI: "+e+" : "+tmp); } } else { hasURIs = false; } boolean blockFinished = Fields.stringToBool(blockFS.get("Finished"), false) && checkURIs[i] != null; if(blockFinished && checkURIs[i] == null) { Logger.error(this, "No URI for check block "+i+" of "+segNo+" yet apparently finished?"); encoded = false; } if(!blockFinished) { SimpleFieldSet bucketFS = blockFS.subset("Data"); if(bucketFS != null) { try { checkBlocks[i] = SerializableToFieldSetBucketUtil.create(bucketFS, ctx.random, ctx.persistentFileTracker); } catch (CannotCreateFromFieldSetException e) { Logger.error(this, "Failed to deserialize check block "+i+" of "+segNo+" : "+e, e); checkBlocks[i] = null; encoded = false; } if(checkBlocks[i] == null) throw new ResumeException("Check block "+i+" of "+segNo+" not finished but no data (create returned null)"); } } else blocksCompleted++; if(checkBlocks[i] == null && checkURIs[i] == null) { Logger.normal(this, "Clearing encoded because block "+i+" of "+segNo+" missing"); encoded = false; } checkFS.removeSubset(index); } splitfileAlgo = FECCodec.getCodec(splitfileAlgorithm, dataBlockCount, checkBlocks.length); } else { Logger.normal(this, "Not encoded because no check blocks"); encoded = false; splitfileAlgo = FECCodec.getCodec(splitfileAlgorithm, dataBlockCount); int checkBlocksCount = splitfileAlgo.countCheckBlocks(); this.checkURIs = new FreenetURI[checkBlocksCount]; this.checkBlocks = new Bucket[checkBlocksCount]; this.checkBlockInserters = new SingleBlockInserter[checkBlocksCount]; hasURIs = false; } for(int i=0;i<dataBlockCount;i++) { String index = Integer.toString(i); SimpleFieldSet blockFS = dataFS.subset(index); if(blockFS == null) throw new ResumeException("No data block "+i+" on segment "+segNo); tmp = blockFS.get("URI"); if(tmp != null) { try { dataURIs[i] = new FreenetURI(tmp); blocksGotURI++; } catch (MalformedURLException e) { throw new ResumeException("Corrupt URI: "+e+" : "+tmp); } } else hasURIs = false; boolean blockFinished = Fields.stringToBool(blockFS.get("Finished"), false); if(blockFinished && dataURIs[i] == null) throw new ResumeException("Block "+i+" of "+segNo+" finished but no URI"); if(!blockFinished) finished = false; else blocksCompleted++; SimpleFieldSet bucketFS = blockFS.subset("Data"); if(bucketFS == null) { if(!blockFinished) throw new ResumeException("Block "+i+" of "+segNo+" not finished but no data"); else if(splitfileAlgorithm > 0 && !encoded) throw new ResumeException("Block "+i+" of "+segNo+" data not available even though not encoded"); } else { try { dataBlocks[i] = SerializableToFieldSetBucketUtil.create(bucketFS, ctx.random, ctx.persistentFileTracker); } catch (CannotCreateFromFieldSetException e) { throw new ResumeException("Failed to deserialize block "+i+" of "+segNo+" : "+e, e); } if(dataBlocks[i] == null) throw new ResumeException("Block "+i+" of "+segNo+" could not serialize data (create returned null) from "+bucketFS); } dataFS.removeSubset(index); } if(!encoded) { finished = false; hasURIs = false; for(int i=0;i<dataBlocks.length;i++) if(dataBlocks[i] == null) throw new ResumeException("Missing data block "+i+" and need to reconstruct check blocks"); } | this.errors = new FailureCodeTracker(true); this.blockInsertContext = blockInsertContext; this.splitfileAlgo = splitfileAlgo; this.dataBlocks = origDataBlocks; int checkBlockCount = splitfileAlgo == null ? 0 : splitfileAlgo.countCheckBlocks(); checkBlocks = new Bucket[checkBlockCount]; checkURIs = new FreenetURI[checkBlockCount]; dataURIs = new FreenetURI[origDataBlocks.length]; dataBlockInserters = new SingleBlockInserter[dataBlocks.length]; checkBlockInserters = new SingleBlockInserter[checkBlocks.length]; | public SplitFileInserterSegment(SplitFileInserter parent, SimpleFieldSet fs, short splitfileAlgorithm, InserterContext ctx, boolean getCHKOnly, int segNo) throws ResumeException { this.parent = parent; this.getCHKOnly = getCHKOnly; this.blockInsertContext = ctx; this.segNo = segNo; if(!"SplitFileInserterSegment".equals(fs.get("Type"))) throw new ResumeException("Wrong Type: "+fs.get("Type")); finished = Fields.stringToBool(fs.get("Finished"), false); encoded = true; started = Fields.stringToBool(fs.get("Started"), false); SimpleFieldSet errorsFS = fs.subset("Errors"); if(errorsFS != null) this.errors = new FailureCodeTracker(true, errorsFS); else this.errors = new FailureCodeTracker(true); if(finished && !errors.isEmpty()) toThrow = InserterException.construct(errors); blocksGotURI = 0; blocksCompleted = 0; SimpleFieldSet dataFS = fs.subset("DataBlocks"); if(dataFS == null) throw new ResumeException("No data blocks"); String tmp = dataFS.get("Count"); if(tmp == null) throw new ResumeException("No data block count"); int dataBlockCount; try { dataBlockCount = Integer.parseInt(tmp); } catch (NumberFormatException e) { throw new ResumeException("Corrupt data blocks count: "+e+" : "+tmp); } hasURIs = true; dataBlocks = new Bucket[dataBlockCount]; dataURIs = new FreenetURI[dataBlockCount]; dataBlockInserters = new SingleBlockInserter[dataBlockCount]; // Check blocks first, because if there are missing check blocks, we need // all the data blocks so we can re-encode. SimpleFieldSet checkFS = fs.subset("CheckBlocks"); if(checkFS != null) { tmp = checkFS.get("Count"); if(tmp == null) throw new ResumeException("Check blocks but no check block count"); int checkBlockCount; try { checkBlockCount = Integer.parseInt(tmp); } catch (NumberFormatException e) { throw new ResumeException("Corrupt check blocks count: "+e+" : "+tmp); } checkBlocks = new Bucket[checkBlockCount]; checkURIs = new FreenetURI[checkBlockCount]; checkBlockInserters = new SingleBlockInserter[checkBlockCount]; for(int i=0;i<checkBlockCount;i++) { String index = Integer.toString(i); SimpleFieldSet blockFS = checkFS.subset(index); if(blockFS == null) { hasURIs = false; encoded = false; Logger.normal(this, "Clearing encoded because block "+i+" of "+segNo+" missing"); continue; } tmp = blockFS.get("URI"); if(tmp != null) { try { checkURIs[i] = new FreenetURI(tmp); blocksGotURI++; } catch (MalformedURLException e) { throw new ResumeException("Corrupt URI: "+e+" : "+tmp); } } else { hasURIs = false; } boolean blockFinished = Fields.stringToBool(blockFS.get("Finished"), false) && checkURIs[i] != null; if(blockFinished && checkURIs[i] == null) { Logger.error(this, "No URI for check block "+i+" of "+segNo+" yet apparently finished?"); encoded = false; } // Read data; only necessary if the block isn't finished. if(!blockFinished) { SimpleFieldSet bucketFS = blockFS.subset("Data"); if(bucketFS != null) { try { checkBlocks[i] = SerializableToFieldSetBucketUtil.create(bucketFS, ctx.random, ctx.persistentFileTracker); } catch (CannotCreateFromFieldSetException e) { Logger.error(this, "Failed to deserialize check block "+i+" of "+segNo+" : "+e, e); // Re-encode it. checkBlocks[i] = null; encoded = false; } if(checkBlocks[i] == null) throw new ResumeException("Check block "+i+" of "+segNo+" not finished but no data (create returned null)"); } // Don't create fetcher yet; that happens in start() } else blocksCompleted++; if(checkBlocks[i] == null && checkURIs[i] == null) { Logger.normal(this, "Clearing encoded because block "+i+" of "+segNo+" missing"); encoded = false; } checkFS.removeSubset(index); } splitfileAlgo = FECCodec.getCodec(splitfileAlgorithm, dataBlockCount, checkBlocks.length); } else { Logger.normal(this, "Not encoded because no check blocks"); encoded = false; splitfileAlgo = FECCodec.getCodec(splitfileAlgorithm, dataBlockCount); int checkBlocksCount = splitfileAlgo.countCheckBlocks(); this.checkURIs = new FreenetURI[checkBlocksCount]; this.checkBlocks = new Bucket[checkBlocksCount]; this.checkBlockInserters = new SingleBlockInserter[checkBlocksCount]; hasURIs = false; } for(int i=0;i<dataBlockCount;i++) { String index = Integer.toString(i); SimpleFieldSet blockFS = dataFS.subset(index); if(blockFS == null) throw new ResumeException("No data block "+i+" on segment "+segNo); tmp = blockFS.get("URI"); if(tmp != null) { try { dataURIs[i] = new FreenetURI(tmp); blocksGotURI++; } catch (MalformedURLException e) { throw new ResumeException("Corrupt URI: "+e+" : "+tmp); } } else hasURIs = false; boolean blockFinished = Fields.stringToBool(blockFS.get("Finished"), false); if(blockFinished && dataURIs[i] == null) throw new ResumeException("Block "+i+" of "+segNo+" finished but no URI"); if(!blockFinished) finished = false; else blocksCompleted++; // Read data SimpleFieldSet bucketFS = blockFS.subset("Data"); if(bucketFS == null) { if(!blockFinished) throw new ResumeException("Block "+i+" of "+segNo+" not finished but no data"); else if(splitfileAlgorithm > 0 && !encoded) throw new ResumeException("Block "+i+" of "+segNo+" data not available even though not encoded"); } else { try { dataBlocks[i] = SerializableToFieldSetBucketUtil.create(bucketFS, ctx.random, ctx.persistentFileTracker); } catch (CannotCreateFromFieldSetException e) { throw new ResumeException("Failed to deserialize block "+i+" of "+segNo+" : "+e, e); } if(dataBlocks[i] == null) throw new ResumeException("Block "+i+" of "+segNo+" could not serialize data (create returned null) from "+bucketFS); // Don't create fetcher yet; that happens in start() } dataFS.removeSubset(index); } if(!encoded) { finished = false; hasURIs = false; for(int i=0;i<dataBlocks.length;i++) if(dataBlocks[i] == null) throw new ResumeException("Missing data block "+i+" and need to reconstruct check blocks"); } parent.parent.addBlocks(dataURIs.length+checkURIs.length); parent.parent.addMustSucceedBlocks(dataURIs.length+checkURIs.length); } | 8026 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8026/0591129065b7962994e34d81ea2689620fae16ff/SplitFileInserterSegment.java/buggy/src/freenet/client/async/SplitFileInserterSegment.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
5385,
812,
382,
550,
387,
4131,
12,
5521,
812,
382,
550,
387,
982,
16,
4477,
974,
694,
2662,
16,
3025,
1416,
768,
6801,
16,
657,
550,
387,
1042,
1103,
16,
1250,
336,
1792,
4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
5385,
812,
382,
550,
387,
4131,
12,
5521,
812,
382,
550,
387,
982,
16,
4477,
974,
694,
2662,
16,
3025,
1416,
768,
6801,
16,
657,
550,
387,
1042,
1103,
16,
1250,
336,
1792,
4... |
CompareSQL sourceComp = new CompareSQL(sourceTables, targetTables); List<DiffChunk<SQLObject>> diff = sourceComp.generateTableDiffs(); CompareSQL targetComp = new CompareSQL(targetTables, sourceTables); List<DiffChunk<SQLObject>> diff1 = targetComp.generateTableDiffs(); | CompareSQL sourceComp = new CompareSQL(sourceTables, targetTables); List<DiffChunk<SQLObject>> diff = sourceComp .generateTableDiffs(); CompareSQL targetComp = new CompareSQL(targetTables, sourceTables); List<DiffChunk<SQLObject>> diff1 = targetComp .generateTableDiffs(); | public void actionPerformed(ActionEvent e) { startCompareAction.setEnabled(false); CompareDMFrame cf = null; try { SQLObject left = source.getObjectToCompare(); if (left.getChildType() == SQLTable.class) { sourceTables = left.getChildren(); } else { sourceTables = new ArrayList(); } SQLObject right = target.getObjectToCompare(); if (right.getChildType() == SQLTable.class) { targetTables = right.getChildren(); } else { targetTables = new ArrayList(); } // XXX: should do most or all of this work in a worker thread Map<DiffType, AttributeSet> styles = new HashMap<DiffType, AttributeSet>(); { SimpleAttributeSet att = new SimpleAttributeSet(); StyleConstants.setForeground(att, Color.green); styles.put(DiffType.LEFTONLY, att); att = new SimpleAttributeSet(); StyleConstants.setForeground(att, Color.red); styles.put(DiffType.RIGHTONLY, att); att = new SimpleAttributeSet(); StyleConstants.setForeground(att, Color.black); styles.put(DiffType.SAME, att); att = new SimpleAttributeSet(); StyleConstants.setForeground(att, Color.orange); styles.put(DiffType.MODIFIED, att); } CompareSQL sourceComp = new CompareSQL(sourceTables, targetTables); List<DiffChunk<SQLObject>> diff = sourceComp.generateTableDiffs(); CompareSQL targetComp = new CompareSQL(targetTables, sourceTables); List<DiffChunk<SQLObject>> diff1 = targetComp.generateTableDiffs(); DefaultStyledDocument sourceDoc = new DefaultStyledDocument(); DefaultStyledDocument targetDoc = new DefaultStyledDocument(); if (sqlButton.isSelected()) { throw new UnsupportedOperationException( "We don't support DDL generation yet"); } else if (englishButton.isSelected()) { for (DiffChunk<SQLObject> chunk : diff) { sourceDoc.insertString( sourceDoc.getLength(), chunk.getData().toString()+"\n", styles.get(chunk.getType())); } for (DiffChunk<SQLObject> chunk1 : diff1) { targetDoc.insertString( targetDoc.getLength(), chunk1.getData().toString()+"\n", styles.get(chunk1.getType())); } } else { throw new IllegalStateException( "Don't know what type of output to make"); } // get the title string for the compareDMFrame String compMethod = null; if (sqlButton.isSelected()) { compMethod = "SQL"; } else { compMethod = OUTPUT_ENGLISH; } String titleString = "Comparing " +left.getName() + " to " + right.getName() + " using " + compMethod; cf = new CompareDMFrame( sourceDoc, targetDoc, titleString, source.getDatabase()); cf.pack(); cf.setVisible(true); } catch (ArchitectDiffException ex) { JOptionPane.showMessageDialog( CompareDMPanel.this, "Could not perform the diff:\n"+ex.getMessage(), "Diff Error", JOptionPane.ERROR_MESSAGE); logger.error("Couldn't do diff", ex); } catch (ArchitectException exp) { ASUtils.showExceptionDialog( "StartCompareAction failed", exp); logger.error("StartCompareAction failed", exp); } catch (FileNotFoundException ex) { ASUtils.showExceptionDialog("Your file could not be found.", ex); logger.error("File could not be found.", ex); } catch (IOException ex) { ASUtils.showExceptionDialog("Could not read file", ex); logger.error("Could not read file", ex); } catch (BadLocationException ex) { ASUtils.showExceptionDialog("Could not create document for results", ex); logger.error("Could not create document for results", ex); } catch (Exception ex) { ASUtils.showExceptionDialog("Unxepected Exception!", ex); logger.error("Unxepected Exception!", ex); } finally { this.setEnabled(isStartable()); } } | 53257 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/53257/561a8da5f06185bff5888ce0a4e1985fcee845da/CompareDMPanel.java/clean/src/ca/sqlpower/architect/swingui/CompareDMPanel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
26100,
12,
1803,
1133,
425,
13,
288,
1082,
202,
1937,
8583,
1803,
18,
542,
1526,
12,
5743,
1769,
1082,
202,
8583,
16125,
3219,
6080,
273,
446,
31,
1082,
202,
698,
288,
9... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
26100,
12,
1803,
1133,
425,
13,
288,
1082,
202,
1937,
8583,
1803,
18,
542,
1526,
12,
5743,
1769,
1082,
202,
8583,
16125,
3219,
6080,
273,
446,
31,
1082,
202,
698,
288,
9... |
long oglContext = ctxmgr.getOGLContext(); ctxmgr.makeCurrent(oglContext, nwin.getId()); | long oglContext = ctxmgr.getOGLContext(nwin.getId(), oshdc); ctxmgr.makeCurrent(oglContext, nwin.getId(), oshdc); | final void makeCurrent() { long oglContext = ctxmgr.getOGLContext(); ctxmgr.makeCurrent(oglContext, nwin.getId()); OGLContextValidator.validateContext(this); } | 54769 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54769/2a3933ceb6acd258d15cd360277965e79d318a59/OGLGraphics2D.java/clean/modules/awt/src/main/java/common/org/apache/harmony/awt/gl/opengl/OGLGraphics2D.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
727,
918,
1221,
3935,
1435,
288,
3639,
1525,
320,
7043,
1042,
273,
1103,
13552,
18,
588,
51,
11261,
1042,
5621,
3639,
1103,
13552,
18,
6540,
3935,
12,
717,
80,
1042,
16,
290,
8082,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
727,
918,
1221,
3935,
1435,
288,
3639,
1525,
320,
7043,
1042,
273,
1103,
13552,
18,
588,
51,
11261,
1042,
5621,
3639,
1103,
13552,
18,
6540,
3935,
12,
717,
80,
1042,
16,
290,
8082,
18,
... |
support.setBuffer(buffer, startPosition); | support.setBuffer(buffer, startPosition); | private int parseHereDocument(int closeQuote, boolean indent) { int c; ISourcePosition position = support.getPosition(); // int linesave = ruby.getSourceLine(); newtok(); switch (closeQuote) { case '\'' : case '"' : case '`' : while ((c = nextc()) != closeQuote) { tokadd(c); } if (closeQuote == '\'') { closeQuote = 0; } break; default : c = closeQuote; closeQuote = '"'; if (!isIdentifierChar(c)) { errorHandler.handleError(IErrors.WARN, support.getPosition(), Messages.getString("deprecated_bare_<<")); //$NON-NLS-1$ break; } while (isIdentifierChar(c)) { tokadd(c); c = nextc(); } pushback(c); break; } // markFilterSource.mark(); // support.readLine(); ISourcePosition startPosition = support.getPosition(); String buffer = support.readLine() + '\n'; String eos = tok(); StringBuffer sb = new StringBuffer(); IListNode list = null; while (true) { // test if the end of file or end of string is reached. String line = support.readLine(); if (line == null) { errorHandler.handleError(IErrors.COMPILE_ERROR, position, Messages.getString("cannot_found_string_before_eof", eos)); //$NON-NLS-1$ return 0; } else if ((indent && line.trim().startsWith(eos)) || line.startsWith(eos)) { if (line.trim().length() == eos.length()) { // source.addCurrentLine(); break; } } support.unread(line.length() + 1); while (true) { switch (parseString(closeQuote, '\n', '\n')) { case Token.tSTRING : case Token.tXSTRING : yaccValue = (String) yaccValue + '\n'; if (list == null) { sb.append(yaccValue); } else { list.add(new StrNode(support.getPosition(), (String) yaccValue)); } break; case Token.tDSTRING : if (list == null) { list = new DStrNode(support.getPosition()); // FIXME position list.add(new StrNode(support.getPosition(), sb.toString())); } // fall through case Token.tDXSTRING : if (list == null) { list = new DXStrNode(support.getPosition()); // FIXME position list.add(new StrNode(support.getPosition(), sb.toString())); } ListNodeUtil.addAll(list, (IListNode) yaccValue); list.add(new StrNode(support.getPosition(), "\n")); //$NON-NLS-1$ break; case 0 : errorHandler.handleError(IErrors.COMPILE_ERROR, position, Messages.getString("cannot_found_string_before_eof", eos)); //$NON-NLS-1$ return 0; } if (support.getLastRead() == '\n') { // isEOL()) { // source.addCurrentLine(); break; } } } lexState = LexState.EXPR_END; // parserSupport.setHeredocEnd(ruby.getSourceLine()); // ruby.setSourceLine(linesave); //markFilterSource.reset(); support.setBuffer(buffer, startPosition); switch (closeQuote) { case '\0' : case '\'' : case '"' : if (list != null) { yaccValue = list; return Token.tDSTRING; } else { yaccValue = sb.toString(); return Token.tSTRING; } case '`' : if (list != null) { yaccValue = list; return Token.tDXSTRING; } else { yaccValue = sb.toString(); return Token.tXSTRING; } } return 0; } | 45753 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45753/af104711597d4d5b2089320e2517b95b8df14492/RubyYaccLexer.java/buggy/org/jruby/lexer/yacc/RubyYaccLexer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
509,
1109,
26715,
2519,
12,
474,
1746,
10257,
16,
1250,
3504,
13,
288,
202,
202,
474,
276,
31,
202,
202,
45,
1830,
2555,
1754,
273,
2865,
18,
588,
2555,
5621,
202,
202,
759,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
509,
1109,
26715,
2519,
12,
474,
1746,
10257,
16,
1250,
3504,
13,
288,
202,
202,
474,
276,
31,
202,
202,
45,
1830,
2555,
1754,
273,
2865,
18,
588,
2555,
5621,
202,
202,
759,
... |
case ANDEQ: case OREQ: | case LITERAL_is: case LITERAL_isnot: | public final void comparisonExpr() throws RecognitionException, TokenStreamException { returnAST = null; ASTPair currentAST = new ASTPair(); org.exist.xquery.parser.XQueryAST comparisonExpr_AST = null; rangeExpr(); astFactory.addASTChild(currentAST, returnAST); { switch ( LA(1)) { case LITERAL_eq: case LITERAL_ne: case LITERAL_lt: case LITERAL_le: case LITERAL_gt: case LITERAL_ge: { { { switch ( LA(1)) { case LITERAL_eq: { org.exist.xquery.parser.XQueryAST tmp200_AST = null; tmp200_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp200_AST); match(LITERAL_eq); break; } case LITERAL_ne: { org.exist.xquery.parser.XQueryAST tmp201_AST = null; tmp201_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp201_AST); match(LITERAL_ne); break; } case LITERAL_lt: { org.exist.xquery.parser.XQueryAST tmp202_AST = null; tmp202_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp202_AST); match(LITERAL_lt); break; } case LITERAL_le: { org.exist.xquery.parser.XQueryAST tmp203_AST = null; tmp203_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp203_AST); match(LITERAL_le); break; } case LITERAL_gt: { org.exist.xquery.parser.XQueryAST tmp204_AST = null; tmp204_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp204_AST); match(LITERAL_gt); break; } case LITERAL_ge: { org.exist.xquery.parser.XQueryAST tmp205_AST = null; tmp205_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp205_AST); match(LITERAL_ge); break; } default: { throw new NoViableAltException(LT(1), getFilename()); } } } rangeExpr(); astFactory.addASTChild(currentAST, returnAST); } break; } case LITERAL_is: case LITERAL_isnot: { { { switch ( LA(1)) { case LITERAL_is: { org.exist.xquery.parser.XQueryAST tmp206_AST = null; tmp206_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp206_AST); match(LITERAL_is); break; } case LITERAL_isnot: { org.exist.xquery.parser.XQueryAST tmp207_AST = null; tmp207_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp207_AST); match(LITERAL_isnot); break; } default: { throw new NoViableAltException(LT(1), getFilename()); } } } rangeExpr(); astFactory.addASTChild(currentAST, returnAST); } break; } case ANDEQ: case OREQ: { { { switch ( LA(1)) { case ANDEQ: { org.exist.xquery.parser.XQueryAST tmp208_AST = null; tmp208_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp208_AST); match(ANDEQ); break; } case OREQ: { org.exist.xquery.parser.XQueryAST tmp209_AST = null; tmp209_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp209_AST); match(OREQ); break; } default: { throw new NoViableAltException(LT(1), getFilename()); } } } rangeExpr(); astFactory.addASTChild(currentAST, returnAST); } break; } case EOF: case RPAREN: case RCURLY: case COMMA: case LITERAL_empty: case LITERAL_for: case LITERAL_let: case LITERAL_where: case LITERAL_return: case LITERAL_order: case LITERAL_ascending: case LITERAL_descending: case LITERAL_satisfies: case LITERAL_else: case LITERAL_or: case LITERAL_and: case LITERAL_cast: case RPPAREN: { break; } default: boolean synPredMatched116 = false; if (((LA(1)==LT))) { int _m116 = mark(); synPredMatched116 = true; inputState.guessing++; try { { match(LT); match(LT); } } catch (RecognitionException pe) { synPredMatched116 = false; } rewind(_m116); inputState.guessing--; } if ( synPredMatched116 ) { match(LT); match(LT); rangeExpr(); astFactory.addASTChild(currentAST, returnAST); if ( inputState.guessing==0 ) { comparisonExpr_AST = (org.exist.xquery.parser.XQueryAST)currentAST.root; comparisonExpr_AST = (org.exist.xquery.parser.XQueryAST)astFactory.make( (new ASTArray(2)).add((org.exist.xquery.parser.XQueryAST)astFactory.create(BEFORE,"<<")).add(comparisonExpr_AST)); currentAST.root = comparisonExpr_AST; currentAST.child = comparisonExpr_AST!=null &&comparisonExpr_AST.getFirstChild()!=null ? comparisonExpr_AST.getFirstChild() : comparisonExpr_AST; currentAST.advanceChildToEnd(); } } else { boolean synPredMatched118 = false; if (((LA(1)==GT))) { int _m118 = mark(); synPredMatched118 = true; inputState.guessing++; try { { match(GT); match(GT); } } catch (RecognitionException pe) { synPredMatched118 = false; } rewind(_m118); inputState.guessing--; } if ( synPredMatched118 ) { match(GT); match(GT); rangeExpr(); astFactory.addASTChild(currentAST, returnAST); if ( inputState.guessing==0 ) { comparisonExpr_AST = (org.exist.xquery.parser.XQueryAST)currentAST.root; comparisonExpr_AST = (org.exist.xquery.parser.XQueryAST)astFactory.make( (new ASTArray(2)).add((org.exist.xquery.parser.XQueryAST)astFactory.create(AFTER,">>")).add(comparisonExpr_AST)); currentAST.root = comparisonExpr_AST; currentAST.child = comparisonExpr_AST!=null &&comparisonExpr_AST.getFirstChild()!=null ? comparisonExpr_AST.getFirstChild() : comparisonExpr_AST; currentAST.advanceChildToEnd(); } } else if ((_tokenSet_6.member(LA(1)))) { { { switch ( LA(1)) { case EQ: { org.exist.xquery.parser.XQueryAST tmp214_AST = null; tmp214_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp214_AST); match(EQ); break; } case NEQ: { org.exist.xquery.parser.XQueryAST tmp215_AST = null; tmp215_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp215_AST); match(NEQ); break; } case GT: { org.exist.xquery.parser.XQueryAST tmp216_AST = null; tmp216_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp216_AST); match(GT); break; } case GTEQ: { org.exist.xquery.parser.XQueryAST tmp217_AST = null; tmp217_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp217_AST); match(GTEQ); break; } case LT: { org.exist.xquery.parser.XQueryAST tmp218_AST = null; tmp218_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp218_AST); match(LT); break; } case LTEQ: { org.exist.xquery.parser.XQueryAST tmp219_AST = null; tmp219_AST = (org.exist.xquery.parser.XQueryAST)astFactory.create(LT(1)); astFactory.makeASTRoot(currentAST, tmp219_AST); match(LTEQ); break; } default: { throw new NoViableAltException(LT(1), getFilename()); } } } rangeExpr(); astFactory.addASTChild(currentAST, returnAST); } } else { throw new NoViableAltException(LT(1), getFilename()); } }} } comparisonExpr_AST = (org.exist.xquery.parser.XQueryAST)currentAST.root; returnAST = comparisonExpr_AST; } | 2909 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2909/b97968ea5c7509390e358e4f2e731907b80df01b/XQueryParser.java/clean/src/org/exist/xquery/parser/XQueryParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
5826,
4742,
1435,
1216,
9539,
16,
3155,
1228,
503,
288,
9506,
202,
2463,
9053,
273,
446,
31,
202,
202,
9053,
4154,
783,
9053,
273,
394,
9183,
4154,
5621,
202,
202,
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,
202,
482,
727,
918,
5826,
4742,
1435,
1216,
9539,
16,
3155,
1228,
503,
288,
9506,
202,
2463,
9053,
273,
446,
31,
202,
202,
9053,
4154,
783,
9053,
273,
394,
9183,
4154,
5621,
202,
202,
3... |
applicationContext.addMessage("checkBox.customFlag", Locale.getDefault(), checkBoxText); | applicationContext.addMessage("customFlag.description", Locale.getDefault(), checkBoxText); | public void testCreateBoundCheckBoxWithLabelKey() { String checkBoxText = "custom"; applicationContext.addMessage("checkBox.customFlag", Locale.getDefault(), checkBoxText); JCheckBox checkBox = formModel.createBoundCheckBox("customFlag", "flag"); assertCheckBoxBinding(checkBox, "flag", testBean.isFlag()); assertEquals("incorrect key for label", checkBoxText, checkBox.getText()); } | 55916 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55916/92de849d431b6ff35b56ec66cb9ca2f6185cb46f/SwingFormModelTests.java/buggy/test/org/springframework/richclient/forms/SwingFormModelTests.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
1684,
3499,
19174,
1190,
2224,
653,
1435,
288,
202,
202,
780,
866,
3514,
1528,
273,
315,
3662,
14432,
202,
202,
3685,
1042,
18,
1289,
1079,
2932,
1893,
3514,
18,
3662... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
1684,
3499,
19174,
1190,
2224,
653,
1435,
288,
202,
202,
780,
866,
3514,
1528,
273,
315,
3662,
14432,
202,
202,
3685,
1042,
18,
1289,
1079,
2932,
1893,
3514,
18,
3662... |
String targetHandle = ProgramElement.createHandleIdentifier( | String targetHandle = AsmManager.getDefault().getHandleProvider().createHandleIdentifier( | public void addDeclareParentsRelationship(ISourceLocation decp,ResolvedTypeX targetType, List newParents) { if (!AsmManager.isCreatingModel()) return; String sourceHandle = ProgramElement.createHandleIdentifier(decp.getSourceFile(),decp.getLine(),decp.getColumn(),decp.getOffset()); IProgramElement ipe = AsmManager.getDefault().getHierarchy().findElementForHandle(sourceHandle); String targetHandle = ProgramElement.createHandleIdentifier( targetType.getSourceLocation().getSourceFile(), targetType.getSourceLocation().getLine(), targetType.getSourceLocation().getColumn(), targetType.getSourceLocation().getOffset()); IRelationshipMap mapper = AsmManager.getDefault().getRelationshipMap(); if (sourceHandle != null && targetHandle != null) { IRelationship foreward = mapper.get(sourceHandle, IRelationship.Kind.DECLARE_INTER_TYPE, INTER_TYPE_DECLARES,false,true); foreward.addTarget(targetHandle); IRelationship back = mapper.get(targetHandle, IRelationship.Kind.DECLARE_INTER_TYPE, INTER_TYPE_DECLARED_BY,false,true); back.addTarget(sourceHandle); } } | 53148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/53148/df7fff4c8c073a3bbcfe749134d577299402d5fb/AsmRelationshipProvider.java/clean/weaver/src/org/aspectj/weaver/AsmRelationshipProvider.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
527,
3456,
834,
13733,
8180,
12,
45,
1830,
2735,
2109,
84,
16,
12793,
559,
60,
16065,
16,
987,
394,
13733,
13,
288,
202,
565,
309,
16051,
1463,
81,
1318,
18,
291,
11092,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
527,
3456,
834,
13733,
8180,
12,
45,
1830,
2735,
2109,
84,
16,
12793,
559,
60,
16065,
16,
987,
394,
13733,
13,
288,
202,
565,
309,
16051,
1463,
81,
1318,
18,
291,
11092,
... |
public org.quickfix.field.UnderlyingSecurityAltIDSource getUnderlyingSecurityAltIDSource() throws FieldNotFound { org.quickfix.field.UnderlyingSecurityAltIDSource value = new org.quickfix.field.UnderlyingSecurityAltIDSource(); | public quickfix.field.UnderlyingSecurityAltIDSource getUnderlyingSecurityAltIDSource() throws FieldNotFound { quickfix.field.UnderlyingSecurityAltIDSource value = new quickfix.field.UnderlyingSecurityAltIDSource(); | public org.quickfix.field.UnderlyingSecurityAltIDSource getUnderlyingSecurityAltIDSource() throws FieldNotFound { org.quickfix.field.UnderlyingSecurityAltIDSource value = new org.quickfix.field.UnderlyingSecurityAltIDSource(); getField(value); return value; } | 8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/TradeCaptureReportRequestAck.java/buggy/src/java/src/quickfix/fix44/TradeCaptureReportRequestAck.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
1830,
10833,
765,
6291,
4368,
10655,
734,
1830,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
1830,
10833,
765,
6291,
4368,
10655,
734,
1830,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
... |
protected void setUp() { | protected void setUp() throws CruiseControlException { | protected void setUp() { dir.mkdirs(); ccController = new CruiseControlController(); } | 55334 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55334/78e4fe0a189d6b82c4608d93394668ec083f9f6a/CruiseControlControllerTest.java/clean/main/test/net/sourceforge/cruisecontrol/CruiseControlControllerTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
24292,
1435,
1216,
385,
8653,
784,
3367,
503,
288,
3639,
1577,
18,
24816,
8291,
5621,
3639,
4946,
2933,
273,
394,
385,
8653,
784,
3367,
2933,
5621,
565,
289,
2,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
24292,
1435,
1216,
385,
8653,
784,
3367,
503,
288,
3639,
1577,
18,
24816,
8291,
5621,
3639,
4946,
2933,
273,
394,
385,
8653,
784,
3367,
2933,
5621,
565,
289,
2,
-100,
-100,
-10... |
rubyClass.getSingletonClass().addMethod(name, new WrapperCallable(newMethod, Visibility.PUBLIC)); rubyClass.callMethod("singleton_method_added", builtins.toSymbol(name)); | containingClass.getSingletonClass().addMethod(name, new WrapperCallable(newMethod, Visibility.PUBLIC)); containingClass.callMethod("singleton_method_added", builtins.toSymbol(name)); | public void visitDefnNode(DefnNode iVisited) { RubyModule rubyClass = threadContext.getRubyClass(); if (rubyClass == null) { throw new TypeError(runtime, "No class to add method."); } String name = iVisited.getName(); if (rubyClass == runtime.getClasses().getObjectClass() && name.equals("initialize")) { runtime.getWarnings().warn("redefining Object#initialize may cause infinite loop"); } Visibility visibility = threadContext.getCurrentVisibility(); if (name.equals("initialize") || visibility.isModuleFunction()) { visibility = Visibility.PRIVATE; } else if (visibility.isPublic() && rubyClass == runtime.getClasses().getObjectClass()) { visibility = iVisited.getVisibility(); } DefaultMethod newMethod = new DefaultMethod(iVisited.getBodyNode(), (ArgsNode) iVisited.getArgsNode(), visibility, runtime.getRubyClass()); iVisited.getBodyNode().accept(new CreateJumpTargetVisitor(newMethod)); rubyClass.addMethod(name, newMethod); if (threadContext.getCurrentVisibility().isModuleFunction()) { rubyClass.getSingletonClass().addMethod(name, new WrapperCallable(newMethod, Visibility.PUBLIC)); rubyClass.callMethod("singleton_method_added", builtins.toSymbol(name)); } rubyClass.callMethod("method_added", builtins.toSymbol(name)); } | 47619 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47619/43e9fa2839b5fdb050b372d628601d8a4bcc43a4/EvaluateVisitor.java/buggy/src/org/jruby/evaluator/EvaluateVisitor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
3757,
3262,
82,
907,
12,
3262,
82,
907,
277,
30019,
13,
288,
3639,
19817,
3120,
22155,
797,
273,
2650,
1042,
18,
588,
54,
10340,
797,
5621,
3639,
309,
261,
27768,
797,
422,
4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
3757,
3262,
82,
907,
12,
3262,
82,
907,
277,
30019,
13,
288,
3639,
19817,
3120,
22155,
797,
273,
2650,
1042,
18,
588,
54,
10340,
797,
5621,
3639,
309,
261,
27768,
797,
422,
4... |
public DescriptorValue calculate(IAtom atom, IAtomContainer ac) throws CDKException { return(calculate(atom, ac, null)); | public DescriptorValue calculate(IAtom atom, IAtomContainer varAtomContainerSet) throws CDKException { return(calculate(atom, varAtomContainerSet, null)); | public DescriptorValue calculate(IAtom atom, IAtomContainer ac) throws CDKException { return(calculate(atom, ac, null)); } | 45167 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45167/ec99113e0f93f800602c4a4fb05f8f479b01e00d/RDFProtonDescriptor_GHR_topol.java/clean/src/org/openscience/cdk/qsar/descriptors/atomic/RDFProtonDescriptor_GHR_topol.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
12823,
620,
4604,
12,
45,
3641,
3179,
16,
13922,
1721,
13,
1216,
24570,
288,
565,
327,
12,
11162,
12,
7466,
16,
1721,
16,
446,
10019,
225,
289,
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,
12823,
620,
4604,
12,
45,
3641,
3179,
16,
13922,
1721,
13,
1216,
24570,
288,
565,
327,
12,
11162,
12,
7466,
16,
1721,
16,
446,
10019,
225,
289,
2,
-100,
-100,
-100,
-100,
-100... |
public TypeCode create_struct_tc(String id, | public TypeCode create_struct_tc(String id, | public TypeCode create_struct_tc(String id, String name, org.omg.CORBA.StructMember[] members) { checkTCRepositoryId( id ); checkTCName( name ); // check that member names are legal and unique Hashtable names = new Hashtable() ; for( int i = 0; i < members.length; i++ ) { checkTCMemberType( members[i].type ); boolean fault = false; try { checkTCName( members[i].name ); } catch( BAD_PARAM bp ) { fault = true; } if( names.containsKey( members[i].name ) || fault ) { throw new BAD_PARAM("Illegal struct member name: " + members[i].name + (fault? " (Bad PARAM) ": "" ), 17, CompletionStatus.COMPLETED_NO ); } names.put( members[i].name, "" ); } names.clear(); org.jacorb.orb.TypeCode tc = new org.jacorb.orb.TypeCode( org.omg.CORBA.TCKind._tk_struct, id, name, members); // resolve any recursive references to this TypeCode in its members tc.resolveRecursion(); return tc; } | 46355 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46355/7271c3cbb78470b90b072d36661a5ab67199cc91/ORBSingleton.java/clean/src/org/jacorb/orb/ORBSingleton.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
30332,
752,
67,
1697,
67,
5111,
12,
780,
612,
16,
4766,
1377,
514,
508,
16,
19694,
2358,
18,
362,
75,
18,
9428,
12536,
18,
3823,
4419,
8526,
4833,
13,
565,
288,
3639,
866,
15988,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
30332,
752,
67,
1697,
67,
5111,
12,
780,
612,
16,
4766,
1377,
514,
508,
16,
19694,
2358,
18,
362,
75,
18,
9428,
12536,
18,
3823,
4419,
8526,
4833,
13,
565,
288,
3639,
866,
15988,
... |
String sPrefix = ""; | String sPrefix = ""; | public Composite getSeriesDataSheet(Composite parent, SeriesDefinition seriesdefinition, IUIServiceProvider builder, Object oContext) { Query query = null; if (seriesdefinition.getDesignTimeSeries().getDataDefinition().size() > 0) { query = ((Query) seriesdefinition.getDesignTimeSeries().getDataDefinition().get(0)); } else { query = QueryImpl.create(""); seriesdefinition.getDesignTimeSeries().getDataDefinition().add(query); } String sPrefix = ""; // If container of container is chart, it is a base series if (seriesdefinition.eContainer().eContainer() instanceof Chart) { sPrefix = "X "; } else { sPrefix = "Y "; } String sTitle = query.getDefinition(); if (sTitle == null || "".equals(sTitle)) { sTitle = sPrefix + "Series Definition"; } else { sTitle = sPrefix + "Series Definition (" + sTitle + ")"; } return new DataDefinitionComposite(parent, SWT.NONE, query, seriesdefinition, builder, oContext, sTitle); } | 15160 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/15160/7793e94b4d7fab5891f226c6c937e37d85bebad8/ScatterSeriesUIProvider.java/buggy/chart/org.eclipse.birt.chart.ui.extension/src/org/eclipse/birt/chart/ui/swt/series/ScatterSeriesUIProvider.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
14728,
336,
6485,
751,
8229,
12,
9400,
982,
16,
9225,
1852,
4166,
6907,
16,
3639,
467,
5370,
16300,
2089,
16,
1033,
320,
1042,
13,
565,
288,
3639,
2770,
843,
273,
446,
31,
3639,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
14728,
336,
6485,
751,
8229,
12,
9400,
982,
16,
9225,
1852,
4166,
6907,
16,
3639,
467,
5370,
16300,
2089,
16,
1033,
320,
1042,
13,
565,
288,
3639,
2770,
843,
273,
446,
31,
3639,
3... |
return Pattern.compile(regex).split(this, 0); | return Pattern.compile(regex).split(this, limit); | public String[] split(String regex) { return Pattern.compile(regex).split(this, 0); } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/1b7948b90667ad6e59c157b1700e8034e8813d3a/String.java/buggy/core/src/classpath/5.0/java/lang/String.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
514,
8526,
1416,
12,
780,
3936,
13,
225,
288,
565,
327,
6830,
18,
11100,
12,
7584,
2934,
4939,
12,
2211,
16,
1800,
1769,
225,
289,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
514,
8526,
1416,
12,
780,
3936,
13,
225,
288,
565,
327,
6830,
18,
11100,
12,
7584,
2934,
4939,
12,
2211,
16,
1800,
1769,
225,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
if (!(document instanceof SVGOMDocument)) { throw new TranscoderException(Messages.formatMessage("notsvg", null)); } SVGDocument svgDoc = (SVGDocument)document; SVGSVGElement root = svgDoc.getRootElement(); String parserClassname = (String)hints.get(KEY_XML_PARSER_CLASSNAME); | graphics = new PSDocumentGraphics2D(false); | protected void transcode(Document document, String uri, TranscoderOutput output) throws TranscoderException { if (!(document instanceof SVGOMDocument)) { throw new TranscoderException(Messages.formatMessage("notsvg", null)); } SVGDocument svgDoc = (SVGDocument)document; SVGSVGElement root = svgDoc.getRootElement(); // initialize the SVG document with the appropriate context String parserClassname = (String)hints.get(KEY_XML_PARSER_CLASSNAME); PSDocumentGraphics2D graphics = new PSDocumentGraphics2D(false); // build the GVT tree GVTBuilder builder = new GVTBuilder(); BridgeContext ctx = new BridgeContext(userAgent); TextPainter textPainter = null; textPainter = new StrokingTextPainter(); ctx.setTextPainter(textPainter); SVGTextElementBridge textElementBridge = new PSTextElementBridge(graphics.getFontInfo()); ctx.putBridge(textElementBridge); //PDFAElementBridge pdfAElementBridge = new PDFAElementBridge(); //AffineTransform currentTransform = new AffineTransform(1, 0, 0, 1, 0, 0); //pdfAElementBridge.setCurrentTransform(currentTransform); //ctx.putBridge(pdfAElementBridge); //ctx.putBridge(new PSImageElementBridge()); GraphicsNode gvtRoot; try { gvtRoot = builder.build(ctx, svgDoc); } catch (BridgeException ex) { throw new TranscoderException(ex); } // get the 'width' and 'height' attributes of the SVG document float docWidth = (float)ctx.getDocumentSize().getWidth(); float docHeight = (float)ctx.getDocumentSize().getHeight(); ctx = null; builder = null; // compute the image's width and height according the hints float imgWidth = -1; if (hints.containsKey(ImageTranscoder.KEY_WIDTH)) { imgWidth = ((Float)hints.get(ImageTranscoder.KEY_WIDTH)).floatValue(); } float imgHeight = -1; if (hints.containsKey(ImageTranscoder.KEY_HEIGHT)) { imgHeight = ((Float)hints.get(ImageTranscoder.KEY_HEIGHT)).floatValue(); } float width, height; if (imgWidth > 0 && imgHeight > 0) { width = imgWidth; height = imgHeight; } else if (imgHeight > 0) { width = (docWidth * imgHeight) / docHeight; height = imgHeight; } else if (imgWidth > 0) { width = imgWidth; height = (docHeight * imgWidth) / docWidth; } else { width = docWidth; height = docHeight; } // compute the preserveAspectRatio matrix AffineTransform px; String ref = null; try { ref = new URL(uri).getRef(); } catch (MalformedURLException ex) { // nothing to do, catched previously } try { px = ViewBox.getViewTransform(ref, root, width, height); } catch (BridgeException ex) { throw new TranscoderException(ex); } if (px.isIdentity() && (width != docWidth || height != docHeight)) { // The document has no viewBox, we need to resize it by hand. // we want to keep the document size ratio float d = Math.max(docWidth, docHeight); float dd = Math.max(width, height); float scale = dd / d; px = AffineTransform.getScaleInstance(scale, scale); } // take the AOI into account if any if (hints.containsKey(ImageTranscoder.KEY_AOI)) { Rectangle2D aoi = (Rectangle2D)hints.get(ImageTranscoder.KEY_AOI); // transform the AOI into the image's coordinate system aoi = px.createTransformedShape(aoi).getBounds2D(); AffineTransform mx = new AffineTransform(); double sx = width / aoi.getWidth(); double sy = height / aoi.getHeight(); mx.scale(sx, sy); double tx = -aoi.getX(); double ty = -aoi.getY(); mx.translate(tx, ty); // take the AOI transformation matrix into account // we apply first the preserveAspectRatio matrix px.preConcatenate(mx); } // prepare the image to be painted int w = (int)width; int h = (int)height; try { graphics.setupDocument(output.getOutputStream(), w, h); graphics.setSVGDimension(docWidth, docHeight); if (hints.containsKey(ImageTranscoder.KEY_BACKGROUND_COLOR)) { graphics.setBackgroundColor((Color)hints.get(ImageTranscoder.KEY_BACKGROUND_COLOR)); } graphics.setGraphicContext(new org.apache.batik.ext.awt.g2d.GraphicContext()); graphics.setTransform(px); gvtRoot.paint(graphics); graphics.finish(); } catch (IOException ex) { throw new TranscoderException(ex); } } | 5268 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5268/b11b73a25c81ba4af3c1d8e6ce14c506e02e85fe/PSTranscoder.java/buggy/src/java/org/apache/fop/render/ps/PSTranscoder.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
906,
710,
12,
2519,
1668,
16,
514,
2003,
16,
11794,
2604,
3396,
1447,
876,
13,
1216,
2604,
3396,
503,
288,
3639,
309,
16051,
12,
5457,
1276,
11281,
1872,
2519,
3719,
288,
5411,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
906,
710,
12,
2519,
1668,
16,
514,
2003,
16,
11794,
2604,
3396,
1447,
876,
13,
1216,
2604,
3396,
503,
288,
3639,
309,
16051,
12,
5457,
1276,
11281,
1872,
2519,
3719,
288,
5411,... |
default: | case CharStream.EOS : { break CONSUME_LOOP; } default : | public Token nextToken() throws IOException, LexerException { Token token = null; OUTER_LOOP: while ( token == null ) { char c = la(); ROOT_SWITCH: switch ( c ) { case ( CharStream.EOS ): { break OUTER_LOOP; } case ( ' ' ): case ( '\t' ): { consume(); token = null; break ROOT_SWITCH; } case ( '\r' ): { consume(); if ( la() == '\n' ) { consume(); token = Token.newline( getStartLine(), getStartColumn() ); } else { token = null; } eol(); break ROOT_SWITCH; } case ( '\n' ): { consume(); if ( la() == '\r') { consume(); } eol(); token = Token.newline( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '{' ): { mark(); consume(); token = Token.leftCurlyBrace( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '}' ): { mark(); consume(); token = Token.rightCurlyBrace( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '[' ): { mark(); consume(); token = Token.leftSquareBracket( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( ']' ): { mark(); consume(); token = Token.rightSquareBracket( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '(' ): { mark(); consume(); token = Token.leftParenthesis( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( ')' ): { mark(); consume(); token = Token.rightParenthesis( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '.' ): { mark(); consume(); if ( la() == '.' ) { consume(); token = Token.dotDot( getStartLine(), getStartColumn() ); } else { token = Token.dot( getStartLine(), getStartColumn() ); } break ROOT_SWITCH; } case ( '#' ): { consume(); CONSUME_LOOP: while ( true ) { switch ( la() ) { case ( '\r' ): { consume(); if ( la() == '\n' ) { consume(); } eol(); break CONSUME_LOOP; } case ( '\n' ): { consume(); eol(); break CONSUME_LOOP; } default: { consume(); } } } token = null; break ROOT_SWITCH; } case ( '/' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '=' ): { consume(); token = Token.divideEqual( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } case ( '/' ): { consume(); CONSUME_LOOP: while ( true ) { switch ( la() ) { case ( '\r' ): { consume(); if ( la() == '\n' ) { consume(); } eol(); break CONSUME_LOOP; } case ( '\n' ): { consume(); eol(); break CONSUME_LOOP; } default: { consume(); } } } token = null; break MULTICHAR_SWITCH; } case ( '*' ): { CONSUME_LOOP: while ( true ) { CONSUME_SWITCH: switch ( la() ) { case ( '*' ): { consume(); if ( la() == '/' ) { consume(); break CONSUME_LOOP; } break CONSUME_SWITCH; } case ( '\r' ): { consume(); if ( la() == '\n' ) { consume(); } eol(); break CONSUME_SWITCH; } case ( '\n' ): { eol(); consume(); break CONSUME_SWITCH; } default: { consume(); } } } token = null; break MULTICHAR_SWITCH; } default: { token = Token.divide( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '%' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '=' ): { consume(); token = Token.modEqual( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.mod( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '~' ): { mark(); consume(); // Support ~<double quoted string> token = Token.patternRegex( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '!' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '=' ): { consume(); token = Token.compareNotEqual( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.not( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '=' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '=' ): { consume(); c = la(); switch ( c ) { case '=': { consume(); token = Token.compareIdentical( getStartLine(), getStartColumn() ); break; } case '~': { consume(); token = Token.matchRegex( getStartLine(), getStartColumn()); break; } default: { token = Token.compareEqual( getStartLine(), getStartColumn() ); } } break MULTICHAR_SWITCH; } case '~': { consume(); token = Token.findRegex( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.equal( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '&' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '&' ): { consume(); token = Token.logicalAnd( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { throw new UnexpectedCharacterException( getStartLine(), getStartColumn()+1, c, new char[] { '&' } ); } } break ROOT_SWITCH; } case ( '|' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '|' ): { consume(); token = Token.logicalOr( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.pipe( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '+' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '+' ): { consume(); token = Token.plusPlus( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } case ( '=' ): { consume(); token = Token.plusEqual( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.plus( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '-' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '-' ): { consume(); token = Token.minusMinus( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } case ( '=' ): { consume(); token = Token.minusEqual( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } case ( '>' ): { consume(); token = Token.navigate( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.minus( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '*' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch( c ) { case ( '=' ): { consume(); token = Token.multiplyEqual( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.multiply( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( ':' ): { mark(); consume(); token = Token.colon( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( ',' ): { mark(); consume(); token = Token.comma( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( ';' ): { mark(); consume(); token = Token.semicolon( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '?' ): { mark(); consume(); token = Token.question( getStartLine(), getStartColumn() ); break ROOT_SWITCH; } case ( '<' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '=' ): { consume(); c = la(); if ( c == '>' ) { consume(); token = Token.compareTo( getStartLine(), getStartColumn() ); } else { token = Token.compareLessThanEqual( getStartLine(), getStartColumn() ); } break MULTICHAR_SWITCH; } case ( '<' ): { consume(); c = la(); // Long strings can be created by using <<<TOK ... \nTOK // They are exactly like double quoted strings except you don't need to escape anything if ( c == '<' ) { consume(); // The marker consists of everything from the end of the <<< to the end of the line. StringBuffer marker = new StringBuffer(); while((c = la()) != '\n') { marker.append(c); consume(); } consume(); // consume the nextline eol(); // next line mark(); // this is the start of the string StringBuffer stringLiteral = new StringBuffer(); LITERAL_LOOP: while ( true ) { c = la(); LITERAL_SWITCH: switch ( c ) { case ( '\n' ): { eol(); // bump the line number StringBuffer markerBuffer = new StringBuffer(); markerBuffer.append(consume()); for (int i = 0; i < marker.length(); i++) { if (la() != marker.charAt(i)) { stringLiteral.append(markerBuffer); continue LITERAL_LOOP; } c = consume(); markerBuffer.append(c); } break LITERAL_LOOP; } case ( CharStream.EOS ): { throw new UnterminatedStringLiteralException( getStartLine(), getStartColumn() ); } } stringLiteral.append( consume() ); } // Fortunately they have the same semantics as a double quoted string once lexed token = Token.doubleQuoteString( getStartLine(), getStartColumn(), stringLiteral.toString() ); break ROOT_SWITCH; } else { throw new UnexpectedCharacterException( getStartLine(), getStartColumn()+1, c, new char[] { } ); } } default: { token = Token.compareLessThan( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '>' ): { mark(); consume(); c = la(); MULTICHAR_SWITCH: switch ( c ) { case ( '=' ): { consume(); token = Token.compareGreaterThanEqual( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } default: { token = Token.compareGreaterThan( getStartLine(), getStartColumn() ); break MULTICHAR_SWITCH; } } break ROOT_SWITCH; } case ( '\'') : { mark(); consume(); StringBuffer stringLiteral = new StringBuffer(); LITERAL_LOOP: while ( true ) { c = la(); LITERAL_SWITCH: switch ( c ) { case ( '\\' ): { consume(); c = la(); ESCAPE_SWITCH: switch ( c ) { case ( 't' ): { consume(); stringLiteral.append( '\t' ); break ESCAPE_SWITCH; } case ( 'n' ): { consume(); stringLiteral.append( '\n' ); break ESCAPE_SWITCH; } case ( 'r' ): { consume(); stringLiteral.append( '\r' ); break ESCAPE_SWITCH; } default: { stringLiteral.append( consume() ); break ESCAPE_SWITCH; } } break LITERAL_SWITCH; } case ( '\r' ): case ( '\n' ): case ( CharStream.EOS ): { throw new UnterminatedStringLiteralException( getStartLine(), getStartColumn() ); } case ( '\'' ): { consume(); break LITERAL_LOOP; } default: { stringLiteral.append( consume() ); break LITERAL_SWITCH; } } } token = Token.singleQuoteString( getStartLine(), getStartColumn(), stringLiteral.toString() ); break ROOT_SWITCH; } case ( '"' ): { mark(); consume(); StringBuffer stringLiteral = new StringBuffer(); LITERAL_LOOP: while ( true ) { c = la(); LITERAL_SWITCH: switch ( c ) { case ( '\\' ): { consume(); c = la(); ESCAPE_SWITCH: switch ( c ) { case ( 't' ): { consume(); stringLiteral.append( '\t' ); break ESCAPE_SWITCH; } case ( 'n' ): { consume(); stringLiteral.append( '\n' ); break ESCAPE_SWITCH; } case ( 'r' ): { consume(); stringLiteral.append( '\r' ); break ESCAPE_SWITCH; } default: { stringLiteral.append( consume() ); break ESCAPE_SWITCH; } } break LITERAL_SWITCH; } case ( '"' ): { consume(); break LITERAL_LOOP; } case ( '\r' ): case ( '\n' ): case ( CharStream.EOS ): { throw new UnterminatedStringLiteralException( getStartLine(), getStartColumn() ); } default: { stringLiteral.append( consume() ); break LITERAL_SWITCH; } } } token = Token.doubleQuoteString( getStartLine(), getStartColumn(), stringLiteral.toString() ); break ROOT_SWITCH; } case ( '0' ): case ( '1' ): case ( '2' ): case ( '3' ): case ( '4' ): case ( '5' ): case ( '6' ): case ( '7' ): case ( '8' ): case ( '9' ): { mark(); StringBuffer numericLiteral = new StringBuffer(); boolean isFloat = false; while ( c == '0' || c == '1' || c == '2' || c == '3' || c == '4' || c == '5' || c == '6' || c == '7' || c == '8' || c == '9' ) { numericLiteral.append( consume() ); c = la(); } if ( c == '.' ) { if ( ( c = la( 2 ) ) == '.' ) { // int followed by range op, break out. } else { while ( c == '0' || c == '1' || c == '2' || c == '3' || c == '4' || c == '5' || c == '6' || c == '7' || c == '8' || c == '9' ) { if ( !isFloat ) numericLiteral.append( consume() ); isFloat = true; numericLiteral.append( consume() ); c = la(); } } } if ( isFloat ) { token = Token.floatNumber( getStartLine(), getStartColumn(), numericLiteral.toString() ); } else { token = Token.integerNumber( getStartLine(), getStartColumn(), numericLiteral.toString() ); } break ROOT_SWITCH; } default: { mark(); if ( Character.isJavaIdentifierStart( c ) ) { StringBuffer identifier = new StringBuffer(); identifier.append( consume() ); IDENTIFIER_LOOP: while ( true ) { c = la(); if ( Character.isJavaIdentifierPart( c ) ) { identifier.append( consume() ); } else { break IDENTIFIER_LOOP; } } token = Token.keyword( getStartLine(), getStartColumn(), identifier.toString() ); if ( token == null ) { token = Token.identifier( getStartLine(), getStartColumn(), identifier.toString() ); } } else { throw new UnexpectedCharacterException( getStartLine(), getStartColumn()+1, c, new char[] { } ); } break ROOT_SWITCH; } } } return token; } | 6462 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6462/3d37acd34fcf44c4a51bd104ef70043af62c7d99/Lexer.java/buggy/src/main/org/codehaus/groovy/syntax/lexer/Lexer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3155,
9617,
1435,
3639,
1216,
1860,
16,
14234,
503,
565,
288,
3639,
3155,
1147,
273,
446,
31,
1377,
28759,
67,
28677,
30,
3639,
1323,
261,
1147,
422,
446,
262,
3639,
288,
5411,
1149... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3155,
9617,
1435,
3639,
1216,
1860,
16,
14234,
503,
565,
288,
3639,
3155,
1147,
273,
446,
31,
1377,
28759,
67,
28677,
30,
3639,
1323,
261,
1147,
422,
446,
262,
3639,
288,
5411,
1149... |
public final String getKeyBinding( javax.faces.context.FacesContext facesContext) { return engine.getStringProperty(Properties.KEY_BINDING, facesContext); } | public final String getKeyBinding() { return getKeyBinding(null); } | public final String getKeyBinding( javax.faces.context.FacesContext facesContext) { return engine.getStringProperty(Properties.KEY_BINDING, facesContext); } | 6232 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6232/1f1850be471d4b8bfd2f3c50aa61bc39bf91259a/AcceleratorComponent.java/clean/org.rcfaces.core/src/org/rcfaces/core/component/AcceleratorComponent.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
514,
3579,
5250,
12,
5411,
6863,
18,
4601,
18,
2472,
18,
17268,
1042,
22529,
13,
288,
3639,
327,
4073,
18,
588,
780,
1396,
12,
2297,
18,
3297,
67,
2739,
16,
22529,
1769,
565,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
514,
3579,
5250,
12,
5411,
6863,
18,
4601,
18,
2472,
18,
17268,
1042,
22529,
13,
288,
3639,
327,
4073,
18,
588,
780,
1396,
12,
2297,
18,
3297,
67,
2739,
16,
22529,
1769,
565,... |
expectedFullUnitToString, expectedCompletionDietUnitToString, testName); | expectedDietPlusBodyPlusStatementsRecoveryUnitToString, expectedFullUnitToString, expectedCompletionDietUnitToString, testName); | public void test75() { String s = "package ZKentTest;\n"+ "\n"+ "import java.awt.color.*;\n"+ "\n"+ "public class A {\n"+ " A foo(int i) { return this; }\n"+ " int[] ii = {0, 1clone()\n"+ "\n"+ " int bar() {\n"+ " class Local {\n"+ " int hello(){\n"+ " fo\n"+ " }\n"+ " int world()\n"+ " }\n"+ " void foo() {\n"+ " ba \n"; String expectedDietUnitToString = "package ZKentTest;\n" + "import java.awt.color.*;\n" + "public class A {\n" + " int[] ii;\n" + " public A() {\n" + " }\n" + " A foo(int i) {\n" + " }\n" + " int bar() {\n" + " }\n" + "}\n"; String expectedDietPlusBodyUnitToString = "package ZKentTest;\n" + "import java.awt.color.*;\n" + "public class A {\n" + " int[] ii;\n" + " public A() {\n" + " super();\n" + " }\n" + " A foo(int i) {\n" + " return this;\n" + " }\n" + " int bar() {\n" + " }\n" + "}\n"; String expectedFullUnitToString = expectedDietUnitToString; String expectedCompletionDietUnitToString = "package ZKentTest;\n" + "import java.awt.color.*;\n" + "public class A {\n" + " int[] ii;\n" + " public A() {\n" + " }\n" + " A foo(int i) {\n" + " }\n" + " clone() {\n" + " }\n" + " int bar() {\n" + " }\n" + "}\n"; String testName = "<bunch of syntax errors>"; checkParse( s.toCharArray(), expectedDietUnitToString, expectedDietPlusBodyUnitToString, expectedFullUnitToString, expectedCompletionDietUnitToString, testName);} | 10698 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10698/ba0154713ba7d434aa2e47b80fd55a84048c10dc/DietRecoveryTest.java/buggy/org.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/parser/DietRecoveryTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
918,
1842,
5877,
1435,
288,
202,
780,
272,
273,
3196,
202,
6,
5610,
29878,
319,
4709,
9747,
82,
6,
15,
202,
202,
12691,
82,
6,
15,
202,
202,
6,
5666,
2252,
18,
2219,
88,
18,
3266,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
918,
1842,
5877,
1435,
288,
202,
780,
272,
273,
3196,
202,
6,
5610,
29878,
319,
4709,
9747,
82,
6,
15,
202,
202,
12691,
82,
6,
15,
202,
202,
6,
5666,
2252,
18,
2219,
88,
18,
3266,
... |
generate( outputDirectory, mavenMojoDescriptors, project ); | generate( getOutputDirectory(), mavenMojoDescriptors, project ); | public void execute() throws PluginExecutionException { try { Set mavenMojoDescriptors = mojoScanner.execute( project ); generate( outputDirectory, mavenMojoDescriptors, project ); } catch ( Exception e ) { // TODO: improve error handling throw new PluginExecutionException( "Error generating plugin descriptor", e ); } } | 11530 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11530/ab91b7f4c29e6f0f9421e0cc03eedeffe9b478f5/AbstractGeneratorMojo.java/clean/maven-plugins/maven-plugin-plugin/src/main/java/org/apache/maven/plugin/plugin/AbstractGeneratorMojo.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1836,
1435,
3639,
1216,
6258,
14576,
565,
288,
3639,
775,
3639,
288,
5411,
1000,
20499,
49,
10007,
12705,
273,
312,
10007,
11338,
18,
8837,
12,
1984,
11272,
5411,
2103,
12,
11062... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1836,
1435,
3639,
1216,
6258,
14576,
565,
288,
3639,
775,
3639,
288,
5411,
1000,
20499,
49,
10007,
12705,
273,
312,
10007,
11338,
18,
8837,
12,
1984,
11272,
5411,
2103,
12,
11062... |
private void load(InputStream in, String ref, boolean flipped, int filter) throws SlickException { | private void load(InputStream in, String ref, boolean flipped, int filter, Color transparent) throws SlickException { | private void load(InputStream in, String ref, boolean flipped, int filter) throws SlickException { try { this.ref = ref; texture = TextureLoader.get().getTexture(in, ref, flipped, filter == FILTER_LINEAR ? GL11.GL_LINEAR : GL11.GL_NEAREST); } catch (IOException e) { Log.error(e); throw new SlickException("Failed to load image from: "+ref, e); } } | 47738 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47738/17eee815b89a0a2b5bd03e4ca3a6f9afde5ea397/Image.java/buggy/src/org/newdawn/slick/Image.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1262,
12,
4348,
316,
16,
514,
1278,
16,
1250,
28821,
16,
509,
1034,
13,
1216,
9708,
1200,
503,
288,
202,
202,
698,
288,
1082,
202,
2211,
18,
1734,
273,
1278,
31,
1082,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1262,
12,
4348,
316,
16,
514,
1278,
16,
1250,
28821,
16,
509,
1034,
13,
1216,
9708,
1200,
503,
288,
202,
202,
698,
288,
1082,
202,
2211,
18,
1734,
273,
1278,
31,
1082,
... |
bean.end(writer, null); | bean.end(writer, ""); | public boolean render(InternalContextAdapter ctx, Writer writer, Node node) throws IOException, ResourceNotFoundException, ParseErrorException, MethodInvocationException { // get the bean OgnlValueStack stack = (OgnlValueStack) ctx.get("stack"); HttpServletRequest req = (HttpServletRequest) stack.getContext().get(ServletActionContext.HTTP_REQUEST); HttpServletResponse res = (HttpServletResponse) stack.getContext().get(ServletActionContext.HTTP_RESPONSE); Component bean = getBean(stack, req, res); // get the parameters Map params = createPropertyMap(ctx, node); bean.copyParams(params); //bean.addAllParameters(params); bean.start(writer); if (getType() == BLOCK) { Node body = node.jjtGetChild(node.jjtGetNumChildren() - 1); body.render(ctx, writer); } bean.end(writer, null); return true; } | 22725 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/22725/5089b08bed44f1f9171a0fbd7280c189c551fc7e/AbstractDirective.java/buggy/src/java/com/opensymphony/webwork/views/velocity/components/AbstractDirective.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1250,
1743,
12,
3061,
1042,
4216,
1103,
16,
5497,
2633,
16,
2029,
756,
13,
1216,
1860,
16,
16676,
16,
2884,
10009,
16,
2985,
9267,
503,
288,
3639,
368,
336,
326,
3931,
3639,
531,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1743,
12,
3061,
1042,
4216,
1103,
16,
5497,
2633,
16,
2029,
756,
13,
1216,
1860,
16,
16676,
16,
2884,
10009,
16,
2985,
9267,
503,
288,
3639,
368,
336,
326,
3931,
3639,
531,
... |
f.hide(); | f.setVisible(false); | public void run() { f.hide(); } | 12183 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12183/b1361b960381803e11284de810a5098c0fb4ec38/MdiWindowManager.java/clean/trunk/client/src/org/lucane/client/util/MdiWindowManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1875,
202,
482,
918,
1086,
1435,
288,
9506,
202,
74,
18,
11248,
5621,
1082,
202,
97,
202,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1875,
202,
482,
918,
1086,
1435,
288,
9506,
202,
74,
18,
11248,
5621,
1082,
202,
97,
202,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
/* no more sfe * * todo: remove after checking new spec | private void insertFaultMessage(ContextHolder holder, ProtocolException exception) { try { SOAPMessageContext context = holder.getSMC(); // avoid NPE in xml binding until this is done if (context == null) { return; } // end hack SOAPMessage message = context.getMessage(); SOAPEnvelope envelope = message.getSOAPPart().getEnvelope(); SOAPBody body = envelope.getBody(); if (body.hasFault()) { return; } if (envelope.getHeader() != null) { envelope.getHeader().detachNode(); } body.removeContents(); SOAPFault fault = body.addFault();/* no more sfe * * todo: remove after checking new spec // try to handle any nulls gracefully if (exception instanceof SOAPFaultException) { SOAPFaultException sfe = (SOAPFaultException) exception; if (sfe.getFaultCode() != null) { fault.setFaultCode(envelope.createName( sfe.getFaultCode().getLocalPart(), sfe.getFaultCode().getPrefix(), sfe.getFaultCode().getNamespaceURI())); } else { fault.setFaultCode(envelope.createName("Server", "env", "http://schemas.xmlsoap.org/soap/envelope/")); } if (sfe.getFaultString() != null) { fault.setFaultString(sfe.getFaultString()); } else { if (sfe.getMessage() != null) { fault.setFaultString(sfe.getMessage()); } else { fault.setFaultString(sfe.toString()); } } if (sfe.getFaultActor() != null) { fault.setFaultActor(sfe.getFaultActor()); } else { fault.setFaultActor(""); } if (sfe.getDetail() != null) { fault.addChildElement(sfe.getDetail()); } } else if (exception.getMessage() != null) { */ if (exception.getMessage() != null) { fault.setFaultCode(envelope.createName("Server", "env", "http://schemas.xmlsoap.org/soap/envelope/")); if (exception.getMessage() != null) { fault.setFaultString(exception.getMessage()); } else { fault.setFaultString(exception.toString()); } } } catch (Exception e) { logger.log(Level.FINER, "exception while creating fault message", e); throw new RuntimeException(e); } } | 9667 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9667/f79abd5cbf7b41525411f40806df7beaaf71a5d5/HandlerChainCaller.java/buggy/jaxws-ri/rt/src/com/sun/xml/ws/handler/HandlerChainCaller.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
2243,
7083,
1079,
12,
1042,
6064,
10438,
16,
3639,
4547,
503,
1520,
13,
288,
3639,
775,
288,
5411,
16434,
1079,
1042,
819,
273,
10438,
18,
588,
7303,
39,
5621,
13491,
368,
4543... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2243,
7083,
1079,
12,
1042,
6064,
10438,
16,
3639,
4547,
503,
1520,
13,
288,
3639,
775,
288,
5411,
16434,
1079,
1042,
819,
273,
10438,
18,
588,
7303,
39,
5621,
13491,
368,
4543... | |
StringTokenizer stDirectory = new StringTokenizer(elem, fromDirSep, true); String token = null; while ( stDirectory.hasMoreTokens() ) { token = stDirectory.nextToken(); if (fromDirSep.equals(token)) { rslt.append( dirSep ); } else { rslt.append( token ); } } | String value = rslt.toString(); log( "Set property " + property + " = " + value, Project.MSG_VERBOSE ); getProject().setNewProperty( property, value ); } finally { path = savedPath; dirSep = savedDirSep; pathSep = savedPathSep; | public void execute() throws BuildException { // If we are a reference, create a Path from the reference if( isReference() ) { path = new Path(getProject()).createPath(); Object obj = refid.getReferencedObject(getProject()); if( obj instanceof Path ) { path.setRefid(refid); } else if( obj instanceof FileSet ) { FileSet fs = (FileSet)obj; path.addFileset( fs ); } else if( obj instanceof DirSet ) { DirSet ds = (DirSet)obj; path.addDirset( ds ); } else if( obj instanceof FileList ) { FileList fl = (FileList)obj; path.addFilelist( fl ); } else { throw new BuildException( "'refid' does not refer to a path, fileset, dirset, or filelist." ); } } validateSetup(); // validate our setup // Currently, we deal with only two path formats: Unix and Windows // And Unix is everything that is not Windows // (with the exception for NetWare below) // for NetWare and OS/2, piggy-back on Windows, since here and // in the apply code, the same assumptions can be made as with // windows - that \\ is an OK separator, and do comparisons // case-insensitive. onWindows = Os.isFamily("dos"); String fromDirSep = onWindows ? "\\" : "/"; StringBuffer rslt = new StringBuffer( 100 ); // Get the list of path components in canonical form String[] elems = path.list(); for( int i=0; i < elems.length; i++ ) { String elem = elems[i]; elem = mapElement( elem ); // Apply the path prefix map // Now convert the path and file separator characters from the // current os to the target os. if( i != 0 ) { rslt.append( pathSep ); } StringTokenizer stDirectory = new StringTokenizer(elem, fromDirSep, true); String token = null; while ( stDirectory.hasMoreTokens() ) { token = stDirectory.nextToken(); if (fromDirSep.equals(token)) { rslt.append( dirSep ); } else { rslt.append( token ); } } } // Place the result into the specified property String value = rslt.toString(); log( "Set property " + property + " = " + value, Project.MSG_VERBOSE ); getProject().setNewProperty( property, value ); } | 506 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/506/25253f3faa839d0341bdfe9eecb06d8791fcf8ea/PathConvert.java/clean/src/main/org/apache/tools/ant/taskdefs/PathConvert.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1836,
1435,
1216,
18463,
288,
3639,
368,
971,
732,
854,
279,
2114,
16,
752,
279,
2666,
628,
326,
2114,
3639,
309,
12,
353,
2404,
1435,
262,
288,
5411,
589,
273,
394,
2666,
12... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1836,
1435,
1216,
18463,
288,
3639,
368,
971,
732,
854,
279,
2114,
16,
752,
279,
2666,
628,
326,
2114,
3639,
309,
12,
353,
2404,
1435,
262,
288,
5411,
589,
273,
394,
2666,
12... |
} else{ | } else { | protected void setButtonStatus(){ String url = issueURLTextWidget.getText(); if (url.length() > 10 && (url.startsWith("http://") || url.startsWith("https://"))){ String defaultPrefix = MylarPlugin.getDefault().getPreferenceStore().getString(MylarTaskListPrefConstants.DEFAULT_URL_PREFIX); if (url.equals(defaultPrefix)){ getDescButton.setEnabled(false); } else{ getDescButton.setEnabled(true); } } else{ getDescButton.setEnabled(false); } } | 51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/f5185d7e1fba2f63d2c2908053bdfa55e753a2d2/TaskInputDialog.java/clean/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasklist/ui/views/TaskInputDialog.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
444,
3616,
1482,
1435,
95,
202,
202,
780,
880,
273,
5672,
1785,
1528,
4609,
18,
588,
1528,
5621,
9506,
202,
430,
261,
718,
18,
2469,
1435,
405,
1728,
597,
261,
718,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
444,
3616,
1482,
1435,
95,
202,
202,
780,
880,
273,
5672,
1785,
1528,
4609,
18,
588,
1528,
5621,
9506,
202,
430,
261,
718,
18,
2469,
1435,
405,
1728,
597,
261,
718,
18,
... |
{ /* if there is a user cached in the http session use that, * otherwise return the current user */ User user = getUserFromHttpSession(); if(user == null) { user = broker.getUser(); } return user; | { return broker.getUser(); | public User getUser() { /* if there is a user cached in the http session use that, * otherwise return the current user */ User user = getUserFromHttpSession(); if(user == null) { user = broker.getUser(); } return user; } | 2909 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2909/ede857fc4542961e61edfadf8a40391772a3fd4c/XQueryContext.java/buggy/src/org/exist/xquery/XQueryContext.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
2177,
4735,
1435,
202,
95,
202,
202,
20308,
309,
1915,
353,
279,
729,
3472,
316,
326,
1062,
1339,
999,
716,
16,
1082,
380,
3541,
327,
326,
783,
729,
1195,
202,
202,
1299,
729,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2177,
4735,
1435,
202,
95,
202,
202,
20308,
309,
1915,
353,
279,
729,
3472,
316,
326,
1062,
1339,
999,
716,
16,
1082,
380,
3541,
327,
326,
783,
729,
1195,
202,
202,
1299,
729,... |
return getStringProperty( Style.BORDER_BOTTOM_STYLE_PROP ); | return getStringProperty( IStyleModel.BORDER_BOTTOM_STYLE_PROP ); | public String getBorderBottomStyle( ) { return getStringProperty( Style.BORDER_BOTTOM_STYLE_PROP ); } | 15160 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/15160/d802c33711e0d111551ae23575895cd060f085b6/StyleHandle.java/buggy/model/org.eclipse.birt.report.model/src/org/eclipse/birt/report/model/api/StyleHandle.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
2882,
1019,
10393,
2885,
12,
262,
202,
95,
202,
202,
2463,
4997,
1396,
12,
9767,
18,
38,
7954,
67,
28891,
67,
15066,
67,
15811,
11272,
202,
97,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
2882,
1019,
10393,
2885,
12,
262,
202,
95,
202,
202,
2463,
4997,
1396,
12,
9767,
18,
38,
7954,
67,
28891,
67,
15066,
67,
15811,
11272,
202,
97,
2,
-100,
-100,
-100,
-100,... |
public void testTriggerSetSnmpInterfaceIdInIpInterfaceNullIfIndexNoSnmpInterface() throws Exception { if (!isDBTestEnabled()) { return; } m_installer.createSequences(); m_installer.createTables(); m_installer.updatePlPgsql(); m_installer.addStoredProcedures(); executeSQL("INSERT INTO node (nodeId, nodeCreateTime) VALUES ( 1, now() )"); executeSQL("INSERT INTO ipInterface (nodeId, ipAddr, ifIndex) VALUES ( 1, '1.2.3.4', null )"); Statement st = m_installer.m_dbconnection.createStatement(); ResultSet rs = st.executeQuery("SELECT id, snmpInterfaceID from ipInterface"); assertTrue("could not advance to read first row in ResultSet", rs.next()); assertEquals("ipInterface id", 1, rs.getInt(1)); int id = rs.getInt(2); assertTrue("ipInterface snmpInterfaceId to be null (was " + id + ")", rs.wasNull()); assertFalse("ResultSet contains more than one row", rs.next()); } | 11849 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11849/9c0a59382d378a750edf84524762ab71e335b4b3/InstallerDBTest.java/clean/opennms-install/src/test/java/org/opennms/install/InstallerDBTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
6518,
694,
10461,
1291,
1358,
548,
382,
5273,
1358,
2041,
2047,
1016,
2279,
10461,
1291,
1358,
1435,
1216,
1185,
288,
3639,
309,
16051,
291,
2290,
4709,
1526,
10756,
288,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
6518,
694,
10461,
1291,
1358,
548,
382,
5273,
1358,
2041,
2047,
1016,
2279,
10461,
1291,
1358,
1435,
1216,
1185,
288,
3639,
309,
16051,
291,
2290,
4709,
1526,
10756,
288,
5... | ||
return new GlobalScope(); } | return new GlobalScope(); } | public Scope getScopeFor(SimpleNode node) { return new GlobalScope(); } | 41673 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/41673/538c94e77f9158ca084b2f4e8acd2b9c3837f151/GlobalScopeEvaluator.java/clean/pmd/src/net/sourceforge/pmd/symboltable/GlobalScopeEvaluator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1850,
1071,
5468,
19203,
1290,
12,
5784,
907,
756,
13,
288,
2398,
327,
394,
8510,
3876,
5621,
540,
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,
... | [
1,
1,
1,
1,
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,
1850,
1071,
5468,
19203,
1290,
12,
5784,
907,
756,
13,
288,
2398,
327,
394,
8510,
3876,
5621,
540,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
tree.update(new NotOrientedEdge(ot), cost(ot.destination(), v3, quadricMap)); | if (ot.destination() != Vertex.outer) tree.update(new NotOrientedEdge(ot), cost(ot.destination(), v3, quadricMap)); | private boolean contractAllVertices(PAVLSortedTree tree, HashMap quadricMap) { int contracted = 0; HashSet trash = new HashSet(); OTriangle ot = new OTriangle(); NotOrientedEdge sym = new NotOrientedEdge(); while (tree.size() > 0) { NotOrientedEdge edge = (NotOrientedEdge) tree.first(); double cost = tree.remove(edge); assert !tree.containsValue(edge); if (cost > tolerance) break; trash.add(edge); edge.pullAttributes(); if (!edge.hasAttributes(OTriangle.MARKED)) continue; Vertex v1 = edge.origin(); Vertex v2 = edge.destination(); Quadric q1 = (Quadric) quadricMap.get(v1); Quadric q2 = (Quadric) quadricMap.get(v2); // TODO: Move v1 and v2 to an optimal point Vertex v3; if (q1.value(v2.getUV()) + q2.value(v2.getUV()) < q1.value(v1.getUV()) + q2.value(v1.getUV())) v3 = (Vertex) v2.clone(); else v3 = (Vertex) v1.clone(); if (!edge.canContract(v3)) continue; // Keep track of triangles deleted when contracting Triangle t1 = edge.getTri(); OTriangle.symOTri(edge, sym); Triangle t2 = sym.getTri(); // Remove all edges of t1 and t2 from tree for (int i = 0; i < 3; i++) { edge.nextOTri(); tree.remove(edge); assert !tree.containsValue(edge); } for (int i = 0; i < 3; i++) { sym.nextOTri(); tree.remove(sym); assert !tree.containsValue(sym); } Vertex apex1 = edge.apex(); Vertex apex2 = sym.apex(); // Compute quadrics Quadric q3 = new Quadric(); q3.add(q1); q3.add(q2); edge.contract(v3); contracted++; mesh.remove(t1); mesh.remove(t2); // Update edge costs quadricMap.remove(v1); quadricMap.remove(v2); quadricMap.put(v3, q3); if (apex1 != Vertex.outer) ot = v3.findOTriangle(apex1); else ot = v3.findOTriangle(apex2); assert ot != null : ""+edge+"\n"+apex1+"\n"+v3+"\n"+apex1+"\n"+v3.tri; Vertex first = ot.destination(); if (first == Vertex.outer) { ot.nextOTriOrigin(); first = ot.destination(); } assert first != Vertex.outer; while (true) { tree.update(new NotOrientedEdge(ot), cost(ot.destination(), v3, quadricMap)); ot.setAttributes(OTriangle.MARKED); ot.nextOTriOrigin(); if (ot.destination() == first) break; } } logger.info("Number of contracted edges: "+contracted); return contracted > 0; } | 45433 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45433/04b1e6c6dc292811e7778eeeef0e2a7a5ea6df27/DecimateVertex.java/clean/amibe/src/org/jcae/mesh/amibe/algos3d/DecimateVertex.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
1250,
6835,
1595,
13371,
12,
4066,
58,
3045,
24726,
2471,
2151,
16,
4317,
9474,
1512,
863,
13,
202,
95,
202,
202,
474,
6835,
329,
273,
374,
31,
202,
202,
13482,
20703,
273,
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,
202,
1152,
1250,
6835,
1595,
13371,
12,
4066,
58,
3045,
24726,
2471,
2151,
16,
4317,
9474,
1512,
863,
13,
202,
95,
202,
202,
474,
6835,
329,
273,
374,
31,
202,
202,
13482,
20703,
273,
3... |
workDequeue.push(object); | workDeque.push(object); | final void enumerateGrey(VM_Address object) throws VM_PragmaInline { if (Plan.isRCObject(object) && !RCBaseHeader.isGreen(object)) { if (VM_Interface.VerifyAssertions) VM_Interface._assert(RCBaseHeader.isLiveRC(object)); RCBaseHeader.decRC(object, false); workDequeue.push(object); } } | 4011 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4011/24860b53c9e03c051a1189704900fce06c0bccf6/TrialDeletion.java/buggy/rvm/src/vm/memoryManagers/JMTk/utility/TrialDeletion.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
727,
918,
4241,
43,
266,
93,
12,
7397,
67,
1887,
733,
13,
565,
1216,
8251,
67,
2050,
9454,
10870,
288,
565,
309,
261,
5365,
18,
291,
11529,
921,
12,
1612,
13,
597,
401,
11529,
2171,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
727,
918,
4241,
43,
266,
93,
12,
7397,
67,
1887,
733,
13,
565,
1216,
8251,
67,
2050,
9454,
10870,
288,
565,
309,
261,
5365,
18,
291,
11529,
921,
12,
1612,
13,
597,
401,
11529,
2171,
1... |
private void scheduleNoticesForEvent(Event event) { Category log = ThreadCategory.getInstance(getClass()); boolean mapsToNotice = false; try { mapsToNotice = getNotificationManager().hasUei(event.getUei()); } catch (Exception e) { log.error("Couldn't map uei " + event.getUei() + " to a notification entry, not scheduling notice.", e); return; } if (mapsToNotice) { // check to see if notices are turned on for the interface/service // in the event if (continueWithNotice(event)) { Notification[] notifications = null; try { notifications = getNotificationManager().getNotifForEvent(event); } catch (Exception e) { log.error("Couldn't get notification mapping for event " + event.getUei() + ", not scheduling notice.", e); return; } if (notifications != null) { for (int i = 0; i < notifications.length; i++) { Notification notification = notifications[i]; boolean parmsmatched = matchNotificationParameters(event, notification); if (!parmsmatched) { log.debug("Event " + event.getUei() + " did not match parameters for notice " + notification.getName()); return; } log.debug("Event " + event.getUei() + " matched notice " + notification.getName()); int noticeId = 0; try { noticeId = getNotificationManager().getNoticeId(); } catch (Exception e) { log.error("Failed to get a unique id # for notification, exiting this notification", e); return; } Map paramMap = buildParameterMap(notification, event, noticeId); String queueID = (notification.getNoticeQueue() != null ? notification.getNoticeQueue() : "default"); log.debug("destination : " + notification.getDestinationPath()); log.debug("text message: " + (String) paramMap.get(NotificationManager.PARAM_TEXT_MSG)); log.debug("num message : " + (String) paramMap.get(NotificationManager.PARAM_NUM_MSG)); log.debug("subject : " + (String) paramMap.get(NotificationManager.PARAM_SUBJECT)); log.debug("node : " + (String) paramMap.get(NotificationManager.PARAM_NODE)); log.debug("interface : " + (String) paramMap.get(NotificationManager.PARAM_INTERFACE)); log.debug("service : " + (String) paramMap.get(NotificationManager.PARAM_SERVICE)); // get the target and escalation information Path path = null; try { path = m_notifd.getDestinationPathManager().getPath(notification.getDestinationPath()); if (path == null) { log.warn("Unknown destination path " + notification.getDestinationPath() + ". Please check the <destinationPath> tag for the notification " + notification.getName() + " in the notification.xml file."); return; } } catch (Exception e) { log.error("Could not get destination path for " + notification.getDestinationPath() + ", please check the destinationPath.xml for errors.", e); return; } String initialDelay = (path.getInitialDelay() == null ? "0s" : path.getInitialDelay()); Target[] targets = path.getTarget(); Escalate[] escalations = path.getEscalate(); // now check to see if any users are to receive the // notification, if none then generate an event a exit try { if (getUserCount(targets, escalations) == 0) { log.warn("The path " + notification.getDestinationPath() + " assigned to notification " + notification.getName() + " has no targets or escalations specified, not sending notice."); sendNotifEvent(EventConstants.NOTIFICATION_WITHOUT_USERS, "The path " + notification.getDestinationPath() + " assigned to notification " + notification.getName() + " has no targets or escalations specified.", "The message of the notification is as follows: " + (String) paramMap.get(NotificationManager.PARAM_TEXT_MSG)); return; } } catch (Exception e) { log.error("Failed to get count of users in destination path " + notification.getDestinationPath() + ", exiting notification.", e); return; } try { getNotificationManager().insertNotice(noticeId, paramMap); } catch (SQLException e) { log.error("Failed to enter notification into database, exiting this notification", e); return; } long startTime = System.currentTimeMillis() + TimeConverter.convertToMillis(initialDelay); List targetSiblings = new ArrayList(); try { NoticeQueue noticeQueue = (NoticeQueue) m_noticeQueues.get(queueID); processTargets(targets, targetSiblings, noticeQueue, startTime, paramMap, noticeId); processEscalations(escalations, targetSiblings, noticeQueue, startTime, paramMap, noticeId); } catch (Exception e) { log.error("notice not scheduled due to error: ", e); } } } else { log.debug("Event doesn't match a notice: " + event.getUei() + " : " + event.getNodeid() + " : " + event.getInterface() + " : " + event.getService()); } } } else { log.debug("No notice match for uei: " + event.getUei()); } } | 47678 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47678/acd9f3285ecdc4e0e9424b89d8a97348cd0a8ae4/BroadcastEventProcessor.java/buggy/src/services/org/opennms/netmgt/notifd/BroadcastEventProcessor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3238,
6459,
10676,
1248,
1242,
1290,
1133,
12,
1133,
2575,
15329,
4457,
1330,
33,
3830,
4457,
18,
588,
1442,
12,
588,
797,
10663,
6494,
10711,
774,
20127,
33,
5743,
31,
698,
95,
10711,
774,
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,
3238,
6459,
10676,
1248,
1242,
1290,
1133,
12,
1133,
2575,
15329,
4457,
1330,
33,
3830,
4457,
18,
588,
1442,
12,
588,
797,
10663,
6494,
10711,
774,
20127,
33,
5743,
31,
698,
95,
10711,
774,
20... | ||
action.setToolTipText(WorkbenchMessages.getString("Workbench.print.ToolTip")); | action.setToolTipText(WorkbenchMessages.getString("Workbench.printToolTip")); | public IWorkbenchAction create(IWorkbenchWindow window) { if (window == null) { throw new IllegalArgumentException(); } RetargetAction action = new RetargetAction(getId(), WorkbenchMessages.getString("Workbench.print")); //$NON-NLS-1$ //$NON-NLS-2$ action.setToolTipText(WorkbenchMessages.getString("Workbench.print.ToolTip")); //$NON-NLS-1$ window.getPartService().addPartListener(action); action.setActionDefinitionId("org.eclipse.ui.file.print"); //$NON-NLS-1$ action.setImageDescriptor( WorkbenchImages.getImageDescriptor( IWorkbenchGraphicConstants.IMG_CTOOL_PRINT_EDIT)); action.setHoverImageDescriptor( WorkbenchImages.getImageDescriptor( IWorkbenchGraphicConstants.IMG_CTOOL_PRINT_EDIT_HOVER)); action.setDisabledImageDescriptor( WorkbenchImages.getImageDescriptor( IWorkbenchGraphicConstants.IMG_CTOOL_PRINT_EDIT_DISABLED)); return action; } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/041bd5e759c0bce2ddee002925167c673a5abed9/ActionFactory.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/actions/ActionFactory.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
467,
2421,
22144,
1803,
752,
12,
45,
2421,
22144,
3829,
2742,
13,
288,
1082,
202,
430,
261,
5668,
422,
446,
13,
288,
9506,
202,
12849,
394,
2754,
5621,
1082,
202,
97,
1082,
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,
467,
2421,
22144,
1803,
752,
12,
45,
2421,
22144,
3829,
2742,
13,
288,
1082,
202,
430,
261,
5668,
422,
446,
13,
288,
9506,
202,
12849,
394,
2754,
5621,
1082,
202,
97,
1082,
2... |
if ( roundCount > 1 && action1.equals( "custom" ) ) { action1 = CombatSettings.getSetting( encounterLookup, roundCount - 2 ); if ( action1.startsWith( "item" ) ) { String name = (String) TradeableItemDatabase.getMatchingNames( action1.substring(4).trim() ).get(0); action1 = name == null ? "attack" : "item" + TradeableItemDatabase.getItemID( name ); } else if ( action1.startsWith( "skill" ) ) { String name = KoLmafiaCLI.getCombatSkillName( action1.substring(5).trim() ); action1 = name == null ? "attack" : String.valueOf( ClassSkillsDatabase.getSkillID( name ) ); } } | public void nextRound() { clearDataFields(); ++roundCount; // Now, to test if the user should run away from the // battle - this is an HP test. int haltTolerance = (int)( Double.parseDouble( getProperty( "battleStop" ) ) * (double) KoLCharacter.getMaximumHP() ); action1 = getProperty( "battleAction" ); action2 = null; for ( int i = 0; i < RARE_MONSTERS.length; ++i ) if ( encounterLookup.indexOf( RARE_MONSTERS[i] ) != -1 ) client.updateDisplay( ABORT_STATE, "You have encountered the " + encounter ); if ( roundCount > 1 && action1.equals( "custom" ) ) { action1 = CombatSettings.getSetting( encounterLookup, roundCount - 2 ); if ( action1.startsWith( "item" ) ) { String name = (String) TradeableItemDatabase.getMatchingNames( action1.substring(4).trim() ).get(0); action1 = name == null ? "attack" : "item" + TradeableItemDatabase.getItemID( name ); } else if ( action1.startsWith( "skill" ) ) { String name = KoLmafiaCLI.getCombatSkillName( action1.substring(5).trim() ); action1 = name == null ? "attack" : String.valueOf( ClassSkillsDatabase.getSkillID( name ) ); } } if ( roundCount == 1 ) { // If this is the first round, you // actually wind up submitting no // extra data. action1 = "attack"; } else if ( action1.equals( "abort" ) || !KoLmafia.permitsContinue() ) { // If the user has chosen to abort // combat, flag it. action1 = null; } else if ( haltTolerance != 0 && KoLCharacter.getCurrentHP() <= haltTolerance ) { // If you plan on halting the battle // due to HP loss, then flag it. action1 = null; } else if ( action1.startsWith( "run" ) ) { action1 = "runaway"; addFormField( "action", action1 ); } else if ( action1.equals( "attack" ) ) { action1 = "attack"; addFormField( "action", action1 ); } // If the player wants to use an item, make sure he has one else if ( action1.startsWith( "item" ) ) { int itemID = Integer.parseInt( action1.substring( 4 ) ); int itemCount = (new AdventureResult( itemID, 1 )).getCount( KoLCharacter.getInventory() ); if ( itemCount == 0 ) { action1 = "attack"; addFormField( "action", action1 ); } else { addFormField( "action", "useitem" ); addFormField( "whichitem", String.valueOf( itemID ) ); if ( KoLCharacter.hasSkill( "Ambidextrous Funkslinging" ) && itemCount >= 2 ) { action2 = action1; addFormField( "whichitem2", String.valueOf( itemID ) ); } } } // Skills use MP. Make sure the character has enough else if ( KoLCharacter.getCurrentMP() < getActionCost() ) { action1 = "attack"; addFormField( "action", action1 ); } else if ( action1.equals( "moxman" ) ) { action1 = "moxman"; addFormField( "action", action1 ); } // If the player wants to use a skill, make sure he knows it else { String skillName = ClassSkillsDatabase.getSkillName( Integer.parseInt( action1 ) ); if ( KoLmafiaCLI.getCombatSkillName( skillName ) == null ) { action1 = "attack"; addFormField( "action", action1 ); } else { addFormField( "action", "skill" ); addFormField( "whichskill", action1 ); } } } | 50364 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50364/622ab33083af86d6680a52188438327e50f0cfd3/FightRequest.java/buggy/src/net/sourceforge/kolmafia/FightRequest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1024,
11066,
1435,
202,
95,
202,
202,
8507,
751,
2314,
5621,
202,
202,
9904,
2260,
1380,
31,
202,
202,
759,
4494,
16,
358,
1842,
309,
326,
729,
1410,
1086,
10804,
628,
32... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1024,
11066,
1435,
202,
95,
202,
202,
8507,
751,
2314,
5621,
202,
202,
9904,
2260,
1380,
31,
202,
202,
759,
4494,
16,
358,
1842,
309,
326,
729,
1410,
1086,
10804,
628,
32... | |
if (IWOLipsModel.EXT_BUILD.equals(aString) || IWOLipsModel.EXT_DIST.equals(aString)) | if (IWOLipsModel.EXT_BUILD.equals(aString) || IWOLipsModel.EXT_DIST.equals(aString)) | private Image imageForName(Image image, String aString) { if (IWOLipsModel.EXT_BUILD.equals(aString) || IWOLipsModel.EXT_DIST.equals(aString)) return buildImage(image); return image; } | 50596 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50596/5274cca4e1302cff5e85f5d8f3c5daddb71bcf97/WOLabelDecorator.java/buggy/projects/wolips/plugins/org.objectstyle.wolips.ui/java/org/objectstyle/wolips/ui/labeldecorator/WOLabelDecorator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
3421,
1316,
1290,
461,
12,
2040,
1316,
16,
514,
279,
780,
13,
288,
202,
202,
430,
261,
45,
59,
1741,
7146,
1488,
18,
4142,
67,
20215,
18,
14963,
12,
69,
780,
13,
747,
467,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3421,
1316,
1290,
461,
12,
2040,
1316,
16,
514,
279,
780,
13,
288,
202,
202,
430,
261,
45,
59,
1741,
7146,
1488,
18,
4142,
67,
20215,
18,
14963,
12,
69,
780,
13,
747,
467,
... |
if (extFactory != null) { n = (Import)n.ext(extFactory.extImport()); } | n = (Import)n.ext(extFactory.extImport()); | public Import Import(Position pos, Import.Kind kind, String name) { Import n = new Import_c(pos, kind, name); if (extFactory != null) { n = (Import)n.ext(extFactory.extImport()); } return n; } | 11982 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11982/27cff504b65da534a6e4e4ad3ce65fac3c7dbb26/NodeFactory_c.java/clean/src/polyglot/ast/NodeFactory_c.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
6164,
6164,
12,
2555,
949,
16,
6164,
18,
5677,
3846,
16,
514,
508,
13,
288,
3639,
6164,
290,
273,
394,
6164,
67,
71,
12,
917,
16,
3846,
16,
508,
1769,
3639,
309,
261,
408,
1733,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
6164,
6164,
12,
2555,
949,
16,
6164,
18,
5677,
3846,
16,
514,
508,
13,
288,
3639,
6164,
290,
273,
394,
6164,
67,
71,
12,
917,
16,
3846,
16,
508,
1769,
3639,
309,
261,
408,
1733,... |
if (DEBUG > 0) { System.err.println("FlexCache: Received event, clearing cache!"); | if (LOG.isDebugEnabled()) { LOG.debug(Messages.get().key(Messages.LOG_FLEXCACHE_RECEIVED_EVENT_CLEAR_CACHE_0)); | public void cmsEvent(org.opencms.main.CmsEvent event) { if (!isEnabled()) { return; } switch (event.getType()) { case I_CmsEventListener.EVENT_PUBLISH_PROJECT: case I_CmsEventListener.EVENT_CLEAR_CACHES: if (DEBUG > 0) { System.err.println("FlexCache: Received event, clearing cache!"); } clear(); break; case I_CmsEventListener.EVENT_FLEX_PURGE_JSP_REPOSITORY: if (DEBUG > 0) { System.err.println("FlexCache: Received event, purging JSP repository!"); } purgeJspRepository(); break; case I_CmsEventListener.EVENT_FLEX_CACHE_CLEAR: if (DEBUG > 0) { System.err.println("FlexCache: Received event, clearing part of cache!"); } Map m = event.getData(); if (m == null) { break; } Integer it = null; try { it = (Integer)m.get("action"); } catch (Exception e) { // it will be null } if (it == null) { break; } int i = it.intValue(); switch (i) { case C_CLEAR_ALL: clear(); break; case C_CLEAR_ENTRIES: clearEntries(); break; case C_CLEAR_ONLINE_ALL: clearOnline(); break; case C_CLEAR_ONLINE_ENTRIES: clearOnlineEntries(); break; case C_CLEAR_OFFLINE_ALL: clearOffline(); break; case C_CLEAR_OFFLINE_ENTRIES: clearOfflineEntries(); break; default: // no operation } default: // no operation } } | 8585 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8585/1daaf4aefd1d6b603c12a300a1b8191c447b347a/CmsFlexCache.java/clean/src/org/opencms/flex/CmsFlexCache.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
6166,
1133,
12,
3341,
18,
556,
14645,
18,
5254,
18,
4747,
1133,
871,
13,
288,
3639,
309,
16051,
291,
1526,
10756,
288,
5411,
327,
31,
3639,
289,
3639,
1620,
261,
2575,
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,
377,
1071,
918,
6166,
1133,
12,
3341,
18,
556,
14645,
18,
5254,
18,
4747,
1133,
871,
13,
288,
3639,
309,
16051,
291,
1526,
10756,
288,
5411,
327,
31,
3639,
289,
3639,
1620,
261,
2575,
18,
58... |
else { if (sourcesOutputDir == null) { LOG.assertTrue(false, "Sources output dir is null for module \""+module.getName()+"\""); } pairs.add(new OutputDir(sourcesOutputDir, ModuleChunk.ALL_SOURCES)); } | names.append(module.getName()); | public void run() { final String sourcesOutputDir = getOutputDir(module); if (shouldCompileTestsSeparately(module)) { if (sourcesOutputDir != null) { pairs.add(new OutputDir(sourcesOutputDir, ModuleChunk.SOURCES)); } final String testsOutputDir = getTestsOutputDir(module); if (testsOutputDir == null) { LOG.assertTrue(false, "Tests output dir is null for module \""+module.getName()+"\""); } pairs.add(new OutputDir(testsOutputDir, ModuleChunk.TEST_SOURCES)); } else { // both sources and test sources go into the same output if (sourcesOutputDir == null) { LOG.assertTrue(false, "Sources output dir is null for module \""+module.getName()+"\""); } pairs.add(new OutputDir(sourcesOutputDir, ModuleChunk.ALL_SOURCES)); } } | 56598 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56598/6d6431b82f533c519bc5faa852b0fdf11eb86801/BackendCompilerWrapper.java/buggy/source/com/intellij/compiler/impl/javaCompiler/BackendCompilerWrapper.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
6647,
1071,
918,
1086,
1435,
288,
5411,
727,
514,
5550,
1447,
1621,
273,
11062,
1621,
12,
2978,
1769,
5411,
309,
261,
13139,
9937,
14650,
16842,
5173,
12,
2978,
3719,
288,
2868,
309,
261,
10141,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
6647,
1071,
918,
1086,
1435,
288,
5411,
727,
514,
5550,
1447,
1621,
273,
11062,
1621,
12,
2978,
1769,
5411,
309,
261,
13139,
9937,
14650,
16842,
5173,
12,
2978,
3719,
288,
2868,
309,
261,
10141,... |
return js_NaN_date_str; | return jsFunction_NaN_date_str; | private static String date_format(double t, int format) { if (t != t) return js_NaN_date_str; StringBuffer result = new StringBuffer(60); double local = LocalTime(t); /* offset from GMT in minutes. The offset includes daylight savings, if it applies. */ int minutes = (int) Math.floor((LocalTZA + DaylightSavingTA(t)) / msPerMinute); /* map 510 minutes to 0830 hours */ int offset = (minutes / 60) * 100 + minutes % 60; String dateStr = Integer.toString(DateFromTime(local)); String hourStr = Integer.toString(HourFromTime(local)); String minStr = Integer.toString(MinFromTime(local)); String secStr = Integer.toString(SecFromTime(local)); String offsetStr = Integer.toString(offset > 0 ? offset : -offset); int year = YearFromTime(local); String yearStr = Integer.toString(year > 0 ? year : -year); /* Tue Oct 31 09:41:40 GMT-0800 (PST) 2000 */ /* Tue Oct 31 2000 */ /* 09:41:40 GMT-0800 (PST) */ if (format != FORMATSPEC_TIME) { result.append(days[WeekDay(local)]); result.append(" "); result.append(months[MonthFromTime(local)]); if (dateStr.length() == 1) result.append(" 0"); else result.append(" "); result.append(dateStr); result.append(" "); } if (format != FORMATSPEC_DATE) { if (hourStr.length() == 1) result.append("0"); result.append(hourStr); if (minStr.length() == 1) result.append(":0"); else result.append(":"); result.append(minStr); if (secStr.length() == 1) result.append(":0"); else result.append(":"); result.append(secStr); if (offset > 0) result.append(" GMT+"); else result.append(" GMT-"); for (int i = offsetStr.length(); i < 4; i++) result.append("0"); result.append(offsetStr); if (timeZoneFormatter == null) timeZoneFormatter = new java.text.SimpleDateFormat("zzz"); if (timeZoneFormatter != null) { result.append(" ("); java.util.Date date = new Date((long) t); result.append(timeZoneFormatter.format(date)); result.append(")"); } if (format != FORMATSPEC_TIME) result.append(" "); } if (format != FORMATSPEC_TIME) { if (year < 0) result.append("-"); for (int i = yearStr.length(); i < 4; i++) result.append("0"); result.append(yearStr); } return result.toString(); } | 11366 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11366/1f40b84b6c54487dd6f26829d1ebda36a7567a38/NativeDate.java/buggy/js/rhino/org/mozilla/javascript/NativeDate.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
514,
1509,
67,
2139,
12,
9056,
268,
16,
509,
740,
13,
288,
3639,
309,
261,
88,
480,
268,
13,
5411,
327,
3828,
2083,
67,
21172,
67,
712,
67,
701,
31,
3639,
6674,
563,
273,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
514,
1509,
67,
2139,
12,
9056,
268,
16,
509,
740,
13,
288,
3639,
309,
261,
88,
480,
268,
13,
5411,
327,
3828,
2083,
67,
21172,
67,
712,
67,
701,
31,
3639,
6674,
563,
273,
... |
v.addAll(force()); | synchronized (this) { if (otherProperties != null) { v.addAll(otherProperties); } } | protected void fillAllPropertyGroups(Collection v) { v.addAll(force()); } | 10687 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10687/7ea26bd8375cd2fa5f3852ba6b9b652c38bc2c28/AssetSkeletonBase.java/buggy/planning/src/org/cougaar/planning/ldm/asset/AssetSkeletonBase.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
918,
3636,
1595,
1396,
3621,
12,
2532,
331,
13,
288,
565,
3852,
261,
2211,
13,
288,
309,
261,
3011,
2297,
480,
446,
13,
288,
331,
18,
1289,
1595,
12,
3011,
2297,
1769,
289,
289,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4750,
918,
3636,
1595,
1396,
3621,
12,
2532,
331,
13,
288,
565,
3852,
261,
2211,
13,
288,
309,
261,
3011,
2297,
480,
446,
13,
288,
331,
18,
1289,
1595,
12,
3011,
2297,
1769,
289,
289,
... |
return gm.connect(newNode, _content.getOwner(), (Class)ModelFacade.DEPENDENCY); | return gm.connect(newNode, _content.getOwner(), (Class) ModelFacade.DEPENDENCY); | protected Object createEdgeUnder(MutableGraphModel gm, Object newNode) { return gm.connect(newNode, _content.getOwner(), (Class)ModelFacade.DEPENDENCY); } | 7166 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7166/d099086bfb37f6acb8e6fe27c21af918f8847c0a/SelectionComponentInstance.java/buggy/src_new/org/argouml/uml/diagram/deployment/ui/SelectionComponentInstance.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
1033,
752,
6098,
14655,
12,
19536,
4137,
1488,
14125,
16,
1033,
10942,
13,
288,
3639,
327,
14125,
18,
3612,
12,
2704,
907,
16,
389,
1745,
18,
588,
5541,
9334,
261,
797,
13,
3164,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
1033,
752,
6098,
14655,
12,
19536,
4137,
1488,
14125,
16,
1033,
10942,
13,
288,
3639,
327,
14125,
18,
3612,
12,
2704,
907,
16,
389,
1745,
18,
588,
5541,
9334,
261,
797,
13,
3164,
... |
printIdentifier(getConstraintName(null, table, "FK", Integer.toString(idx))); | printIdentifier(getForeignKeyName(table, key)); | protected void writeEmbeddedForeignKeysStmt(Database database, Table table) throws IOException { for (int idx = 0; idx < table.getForeignKeyCount(); idx++) { ForeignKey key = table.getForeignKey(idx); if (key.getForeignTableName() == null) { _log.warn("Foreign key table is null for key " + key); } else { println(","); printIndent(); if (getPlatformInfo().isEmbeddedForeignKeysNamed()) { print("CONSTRAINT "); printIdentifier(getConstraintName(null, table, "FK", Integer.toString(idx))); print(" "); } print("FOREIGN KEY ("); writeLocalReferences(key); print(") REFERENCES "); printIdentifier(getTableName(database.findTable(key.getForeignTableName()))); print(" ("); writeForeignReferences(key); print(")"); } } } | 1224 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1224/96e9d99cb3e336dc8808006ccd7c3b9e723e4ce7/SqlBuilder.java/buggy/src/java/org/apache/ddlutils/platform/SqlBuilder.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
1045,
14980,
28285,
8952,
12,
4254,
2063,
16,
3555,
1014,
13,
1216,
1860,
565,
288,
3639,
364,
261,
474,
2067,
273,
374,
31,
2067,
411,
1014,
18,
588,
15420,
1380,
5621,
2067,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1045,
14980,
28285,
8952,
12,
4254,
2063,
16,
3555,
1014,
13,
1216,
1860,
565,
288,
3639,
364,
261,
474,
2067,
273,
374,
31,
2067,
411,
1014,
18,
588,
15420,
1380,
5621,
2067,
... |
public void readSharedObjects(Repository rep) throws KettleException { // Extract the shared steps, connections, etc. using the SharedObjects class // String soFile = StringUtil.environmentSubstitute(sharedObjectsFile); SharedObjects sharedObjects = new SharedObjects(soFile, databases, counters, slaveServers); Map objectsMap = sharedObjects.getObjectsMap(); Collection objects = objectsMap.values(); // First read the databases... // We read databases & slaves first because there might be dependencies that need to be resolved. // for (Iterator iter = objects.iterator(); iter.hasNext();) { Object object = iter.next(); if (object instanceof DatabaseMeta) { DatabaseMeta databaseMeta = (DatabaseMeta) object; addOrReplaceDatabase(databaseMeta); } } // Then read the slave servers // for (Iterator iter = objects.iterator(); iter.hasNext();) { Object object = iter.next(); if (object instanceof SlaveServer) { SlaveServer slaveServer = (SlaveServer) object; addOrReplaceSlaveServer(slaveServer); } } // Then the rest... /// for (Iterator iter = objects.iterator(); iter.hasNext();) { Object object = iter.next(); if (object instanceof StepMeta) { StepMeta stepMeta = (StepMeta) object; addOrReplaceStep(stepMeta); } else if (object instanceof PartitionSchema) { PartitionSchema partitionSchema = (PartitionSchema) object; addOrReplacePartitionSchema(partitionSchema); } else if (object instanceof ClusterSchema) { ClusterSchema clusterSchema = (ClusterSchema) object; addOrReplaceClusterSchema(clusterSchema); } } if (rep!=null) { readDatabases(rep, true); readPartitionSchemas(rep, true); readSlaves(rep, true); readClusters(rep, true); } } | 58146 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58146/6c6b17bcb3d9c3c6ff1c353c26eb42748486adc8/TransMeta.java/clean/kettle/src/be/ibridge/kettle/trans/TransMeta.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
6459,
896,
7887,
4710,
12,
3305,
14462,
13,
15069,
47,
278,
5929,
503,
95,
759,
4976,
451,
4607,
2258,
8986,
16,
13313,
16,
14175,
18,
9940,
5787,
7887,
921,
1017,
459,
759,
780,
2048,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
6459,
896,
7887,
4710,
12,
3305,
14462,
13,
15069,
47,
278,
5929,
503,
95,
759,
4976,
451,
4607,
2258,
8986,
16,
13313,
16,
14175,
18,
9940,
5787,
7887,
921,
1017,
459,
759,
780,
2048,
... | ||
_serverStatusRequest request = new _serverStatusRequest(); | ServerStatusRequest request = new ServerStatusRequest(); | public ServerStatusType getStatus() throws RemoteException { _serverStatusRequest request = new _serverStatusRequest(); ServerStatusType status = getStub().serverStatus(request); return status; } | 4987 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4987/6a0bce9a04774f0d574902b90826623e639302b9/ConsoleOperation.java/clean/core/components/cddlm/client/org/cddlm/client/console/ConsoleOperation.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3224,
1482,
559,
5870,
1435,
1216,
18361,
288,
3639,
3224,
24696,
590,
273,
394,
3224,
24696,
5621,
3639,
3224,
1482,
559,
1267,
273,
336,
11974,
7675,
3567,
1482,
12,
2293,
1769,
363... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3224,
1482,
559,
5870,
1435,
1216,
18361,
288,
3639,
3224,
24696,
590,
273,
394,
3224,
24696,
5621,
3639,
3224,
1482,
559,
1267,
273,
336,
11974,
7675,
3567,
1482,
12,
2293,
1769,
363... |
java.security.Security.setProperty("networkaddress.cache.ttl" , "300"); | java.security.Security.setProperty("networkaddress.cache.ttl" , "60"); | public static void main(String[] args) throws IOException { if(args.length>1) { System.out.println("Usage: $ java freenet.node.Node <configFile>"); return; } File configFilename; if(args.length == 0) { System.out.println("Using default config filename freenet.ini"); configFilename = new File("freenet.ini"); } else configFilename = new File(args[0]); // set Java's DNS cache not to cache forever, since many people // use dyndns hostnames java.security.Security.setProperty("networkaddress.cache.ttl" , "300"); // set Java's negative DNS cache to 1 minute rather than the default 10 seconds java.security.Security.setProperty("networkaddress.cache.negative.ttl" , "60"); FilePersistentConfig cfg = new FilePersistentConfig(configFilename); // First, set up logging. It is global, and may be shared between several nodes. SubConfig loggingConfig = new SubConfig("logger", cfg); try { logConfigHandler = new LoggingConfigHandler(loggingConfig); } catch (InvalidConfigValueException e) { System.err.println("Error: could not set up logging: "+e.getMessage()); e.printStackTrace(); return; } // Setup RNG RandomSource random = new Yarrow(); DiffieHellman.init(random); Thread t = new Thread(new MemoryChecker(), "Memory checker"); t.setPriority(Thread.MAX_PRIORITY); t.start(); /* SimpleToadletServer server = new SimpleToadletServer(port+2000); FProxyToadlet fproxy = new FProxyToadlet(n.makeClient(RequestStarter.INTERACTIVE_PRIORITY_CLASS)); PProxyToadlet pproxy = new PProxyToadlet(n.makeClient(RequestStarter.INTERACTIVE_PRIORITY_CLASS), n.pluginManager); server.register(fproxy, "/", false); server.register(pproxy, "/plugins/", true); System.out.println("Starting FProxy on port "+(port+2000)); new FCPServer(port+3000, n); System.out.println("Starting FCP server on port "+(port+3000)); //server.register(fproxy, "/SSK@", false); //server.register(fproxy, "/KSK@", false); */ Node node; try { node = new Node(cfg, random, logConfigHandler); node.start(false); } catch (NodeInitException e) { System.err.println("Failed to load node: "+e.getMessage()); e.printStackTrace(); System.exit(e.exitCode); } // Thread to keep the node up. // JVM deadlocks losing a lock when two threads of different types (daemon|app) // are contended for the same lock. So make USM daemon, and use useless to keep the JVM // up. // http://forum.java.sun.com/thread.jspa?threadID=343023&messageID=2942637 - last message Runnable useless = new Runnable() { public void run() { while(true) try { Thread.sleep(Long.MAX_VALUE); } catch (InterruptedException e) { // Ignore } } }; Thread plug = new Thread(useless, "Plug"); plug.start(); } | 50915 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50915/929685dfdd7035cfc64df015d854dc7a84ad8a50/Node.java/buggy/src/freenet/node/Node.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
1216,
1860,
288,
377,
202,
430,
12,
1968,
18,
2469,
34,
21,
13,
288,
377,
202,
202,
3163,
18,
659,
18,
8222,
2932,
5357,
30,
271,
2252,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
1216,
1860,
288,
377,
202,
430,
12,
1968,
18,
2469,
34,
21,
13,
288,
377,
202,
202,
3163,
18,
659,
18,
8222,
2932,
5357,
30,
271,
2252,
... |
PerThread(Scriptable scope, String script, String x) { this.scope = scope; this.script = script; | PerThread(Scriptable sharedScope, String source, String x) { this.sharedScope = sharedScope; this.source = source; | PerThread(Scriptable scope, String script, String x) { this.scope = scope; this.script = script; this.x = x; } | 51275 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51275/8f793c397ef394e598a4b771d5b4396a8355dfd4/DynamicScopes.java/clean/js/rhino/examples/DynamicScopes.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
5722,
3830,
12,
3651,
429,
2146,
16,
514,
2728,
16,
514,
619,
13,
288,
5411,
333,
18,
4887,
273,
2146,
31,
5411,
333,
18,
4263,
273,
2728,
31,
5411,
333,
18,
92,
273,
619,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
5722,
3830,
12,
3651,
429,
2146,
16,
514,
2728,
16,
514,
619,
13,
288,
5411,
333,
18,
4887,
273,
2146,
31,
5411,
333,
18,
4263,
273,
2728,
31,
5411,
333,
18,
92,
273,
619,
31,
3639,
... |
public org.quickfix.field.LegRepoCollateralSecurityType getLegRepoCollateralSecurityType() throws FieldNotFound { org.quickfix.field.LegRepoCollateralSecurityType value = new org.quickfix.field.LegRepoCollateralSecurityType(); | public quickfix.field.LegRepoCollateralSecurityType getLegRepoCollateralSecurityType() throws FieldNotFound { quickfix.field.LegRepoCollateralSecurityType value = new quickfix.field.LegRepoCollateralSecurityType(); | public org.quickfix.field.LegRepoCollateralSecurityType getLegRepoCollateralSecurityType() throws FieldNotFound { org.quickfix.field.LegRepoCollateralSecurityType value = new org.quickfix.field.LegRepoCollateralSecurityType(); getField(value); return value; } | 8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/Confirmation.java/buggy/src/java/src/quickfix/fix44/Confirmation.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
8329,
8791,
13535,
2045,
287,
4368,
559,
336,
8329,
8791,
13535,
2045,
287,
4368,
559,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
8329,
8791,
13535,
2045,
287,
4368,
559,
336,
8329,
8791,
13535,
2045,
287,
4368,
559,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18... |
if(workbenchStatePath == null) return false; | if(workbenchStatePath == null) { return false; } | private boolean readEditors(Map editorTable) { //Get the workbench plugin's working directory IPath workbenchStatePath = WorkbenchPlugin.getDefault().getDataLocation(); if(workbenchStatePath == null) return false; IPreferenceStore store = WorkbenchPlugin.getDefault() .getPreferenceStore(); Reader reader = null; try { // Get the editors defined in the preferences store String xmlString = store.getString(IPreferenceConstants.EDITORS); if (xmlString == null || xmlString.length() == 0) { FileInputStream stream = new FileInputStream(workbenchStatePath .append(IWorkbenchConstants.EDITOR_FILE_NAME) .toOSString()); reader = new BufferedReader(new InputStreamReader(stream, "utf-8")); //$NON-NLS-1$ } else { reader = new StringReader(xmlString); } XMLMemento memento = XMLMemento.createReadRoot(reader); EditorDescriptor editor; IMemento[] edMementos = memento .getChildren(IWorkbenchConstants.TAG_DESCRIPTOR); // Get the editors and validate each one for (int i = 0; i < edMementos.length; i++) { editor = new EditorDescriptor(); boolean valid = editor.loadValues(edMementos[i]); if (!valid) { continue; } if (editor.getPluginID() != null) { //If the editor is from a plugin we use its ID to look it // up in the mapping of editors we //have obtained from plugins. This allows us to verify that // the editor is still valid //and allows us to get the editor description from the // mapping table which has //a valid config element field. EditorDescriptor validEditorDescritor = (EditorDescriptor) mapIDtoEditor .get(editor.getId()); if (validEditorDescritor != null) { editorTable.put(validEditorDescritor.getId(), validEditorDescritor); } } else { //This is either from a program or a user defined // editor ImageDescriptor descriptor; if (editor.getProgram() == null) descriptor = new ProgramImageDescriptor(editor .getFileName(), 0); else descriptor = new ExternalProgramImageDescriptor(editor .getProgram()); editor.setImageDescriptor(descriptor); editorTable.put(editor.getId(), editor); } } } catch (IOException e) { try { if (reader != null) reader.close(); } catch (IOException ex) { e.printStackTrace(); } //Ignore this as the workbench may not yet have saved any state return false; } catch (WorkbenchException e) { ErrorDialog.openError((Shell) null, WorkbenchMessages.EditorRegistry_errorTitle, WorkbenchMessages.EditorRegistry_errorMessage, e.getStatus()); return false; } return true; } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/fa4a8cff0e027f8d3c6b1fcb92b30f46767dd191/EditorRegistry.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/registry/EditorRegistry.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1250,
855,
4666,
1383,
12,
863,
4858,
1388,
13,
288,
3639,
368,
967,
326,
1440,
22144,
1909,
1807,
5960,
1867,
3639,
467,
743,
1440,
22144,
1119,
743,
273,
4147,
22144,
3773,
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,
377,
3238,
1250,
855,
4666,
1383,
12,
863,
4858,
1388,
13,
288,
3639,
368,
967,
326,
1440,
22144,
1909,
1807,
5960,
1867,
3639,
467,
743,
1440,
22144,
1119,
743,
273,
4147,
22144,
3773,
18,
58... |
curArea.setOffset(0); | area.setOffset(0); | protected void offsetArea(LayoutContext context) { int pattern = fobj.getLeaderPattern(); int bpd = curArea.getBPD(); switch (pattern) { case EN_RULE: switch (verticalAlignment) { case EN_TOP: curArea.setOffset(0); break; case EN_MIDDLE: curArea.setOffset(context.getMiddleBaseline() - bpd / 2); break; case EN_BOTTOM: curArea.setOffset(context.getLineHeight() - bpd); break; case EN_BASELINE: // fall through default: curArea.setOffset(context.getBaseline() - bpd); break; } break; case EN_DOTS: switch (verticalAlignment) { case EN_TOP: curArea.setOffset(0); break; case EN_MIDDLE: curArea.setOffset(context.getMiddleBaseline()); break; case EN_BOTTOM: curArea.setOffset(context.getLineHeight() - bpd + font.getAscender()); break; case EN_BASELINE: // fall through default: curArea.setOffset(context.getBaseline()); break; } break; case EN_SPACE: // nothing to do break; case EN_USECONTENT: switch (verticalAlignment) { case EN_TOP: curArea.setOffset(0); break; case EN_MIDDLE: curArea.setOffset(context.getMiddleBaseline()); break; case EN_BOTTOM: curArea.setOffset(context.getLineHeight() - bpd); break; case EN_BASELINE: // fall through default: curArea.setOffset(context.getBaseline()); break; } break; } } | 5268 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5268/5ceefcc7d76554e2cf178d60628e229a03f468fb/LeaderLayoutManager.java/clean/src/java/org/apache/fop/layoutmgr/LeaderLayoutManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
1384,
5484,
12,
3744,
1042,
819,
13,
288,
3639,
509,
1936,
273,
24705,
18,
588,
15254,
3234,
5621,
3639,
509,
9107,
72,
273,
662,
5484,
18,
588,
38,
21527,
5621,
3639,
1620,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1384,
5484,
12,
3744,
1042,
819,
13,
288,
3639,
509,
1936,
273,
24705,
18,
588,
15254,
3234,
5621,
3639,
509,
9107,
72,
273,
662,
5484,
18,
588,
38,
21527,
5621,
3639,
1620,
... |
assertEquals(observer.getUpMessages().size(),1); | assertEquals(1, observer.getUpMessages().size()); | public void testMessageUpNoBuffer() throws Exception{ // initialise the encryption Properties props = new Properties(); String defaultKeystore = "defaultStore.keystore"; props.put("key_store_name",defaultKeystore); //javax. ENCRYPT encrypt = new ENCRYPT(); encrypt.setProperties(props); try { encrypt.init(); } catch (Exception e){ fail(e.getMessage()); } MockObserver observer = new MockObserver(); encrypt.setObserver(observer); encrypt.keyServer = true; Message msg = new Message(null,null,null); Event event = new Event(Event.MSG,msg); encrypt.up(event); assertEquals(observer.getUpMessages().size(),1); } | 51463 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51463/6cf135ab0aec1dba727f94146eb1d03ec797779c/ENCRYPT14KeystoreTest.java/clean/tests/junit/org/jgroups/protocols/ENCRYPT14KeystoreTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
1079,
1211,
2279,
1892,
1435,
1216,
1185,
95,
202,
202,
759,
21301,
326,
8731,
202,
202,
2297,
3458,
273,
394,
6183,
5621,
202,
202,
780,
805,
653,
2233,
273,
315,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
1079,
1211,
2279,
1892,
1435,
1216,
1185,
95,
202,
202,
759,
21301,
326,
8731,
202,
202,
2297,
3458,
273,
394,
6183,
5621,
202,
202,
780,
805,
653,
2233,
273,
315,
... |
} else if (proxy != null && isControllConnection() == true) { | } else { | public void connect(SocketAddress remote, Proxy proxy, int maxDownload, int maxUpload) throws IOException { if (proxy == null) { socket.connect(remote); } else if (proxy != null && isControllConnection() == true) { InetSocketAddress isa = (InetSocketAddress) remote; socket = proxy.connect(isa.getAddress().getHostAddress(), isa .getPort()); } else if (proxy != null && isControllConnection == false) { socket = proxy.bind((InetSocketAddress) remote); } this.maxDownload = maxDownload; this.maxUpload = maxUpload; initStreams(); } | 11835 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11835/d315915279d746a6e1f89b78b1ecbbd5c58072cc/SocketProvider.java/buggy/ftp4che14/src/java/org/ftp4che/io/SocketProvider.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
3077,
12,
15520,
2632,
16,
7659,
2889,
16,
509,
943,
7109,
16,
5411,
509,
943,
4777,
13,
1216,
1860,
288,
3639,
309,
261,
5656,
422,
446,
13,
288,
5411,
2987,
18,
3612,
12,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
3077,
12,
15520,
2632,
16,
7659,
2889,
16,
509,
943,
7109,
16,
5411,
509,
943,
4777,
13,
1216,
1860,
288,
3639,
309,
261,
5656,
422,
446,
13,
288,
5411,
2987,
18,
3612,
12,
... |
private void addRequest() | synchronized private void addRequest() | private void addRequest() { boolean more_pieces = true; while (more_pieces) { synchronized(this) { more_pieces = outstandingRequests.size() < MAX_PIPELINE; } // We want something and we don't have outstanding requests? if (more_pieces && lastRequest == null) more_pieces = requestNextPiece(); else if (more_pieces) // We want something { int pieceLength; boolean isLastChunk; synchronized(this) { pieceLength = metainfo.getPieceLength(lastRequest.piece); isLastChunk = lastRequest.off + lastRequest.len == pieceLength; } // Last part of a piece? if (isLastChunk) more_pieces = requestNextPiece(); else { synchronized(this) { int nextPiece = lastRequest.piece; int nextBegin = lastRequest.off + PARTSIZE; byte[] bs = lastRequest.bs; int maxLength = pieceLength - nextBegin; int nextLength = maxLength > PARTSIZE ? PARTSIZE : maxLength; Request req = new Request(nextPiece, bs, nextBegin, nextLength); outstandingRequests.add(req); if (!choked) out.sendRequest(req); lastRequest = req; } } } } if (_log.shouldLog(Log.DEBUG)) _log.debug(peer + " requests " + outstandingRequests); } | 27493 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/27493/5cf85c1d7b9942ae2d65de227b3396ccf871e46f/PeerState.java/buggy/apps/i2psnark/java/src/org/klomp/snark/PeerState.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3852,
3238,
918,
527,
691,
1435,
225,
288,
565,
1250,
1898,
67,
31016,
273,
638,
31,
565,
1323,
261,
10161,
67,
31016,
13,
1377,
288,
3639,
3852,
12,
2211,
13,
1850,
288,
5411,
1898,
67... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3852,
3238,
918,
527,
691,
1435,
225,
288,
565,
1250,
1898,
67,
31016,
273,
638,
31,
565,
1323,
261,
10161,
67,
31016,
13,
1377,
288,
3639,
3852,
12,
2211,
13,
1850,
288,
5411,
1898,
67... |
assertEquals(new Money("280.0"),totalRepaymentAmount); | assertEquals(new Money("280.0"), totalRepaymentAmount); | public void testMakeEarlyRepaymentOnPartiallyPaidPricipal() throws Exception { MeetingBO meeting = TestObjectFactory.createMeeting(TestObjectFactory .getMeetingHelper(1, 2, 4, 1)); center = TestObjectFactory.createCenter("Center", Short.valueOf("13"), "1.1", meeting, new Date(System.currentTimeMillis())); group = TestObjectFactory.createGroup("Group", Short.valueOf("9"), "1.1.1", center, new Date(System.currentTimeMillis())); LoanOfferingBO loanOffering = TestObjectFactory.createLoanOffering( "Loan", Short.valueOf("2"), new Date(System.currentTimeMillis()), Short.valueOf("1"), 300.0, 1.2, Short.valueOf("3"), Short.valueOf("1"), Short .valueOf("1"), Short.valueOf("1"), Short.valueOf("0"), Short.valueOf("1"), center.getCustomerMeeting().getMeeting()); List<FeeView> feeViewList=new ArrayList<FeeView>(); FeeBO periodicFee = TestObjectFactory.createPeriodicAmountFee("Periodic Fee", FeeCategory.LOAN, "100", MeetingFrequency.WEEKLY, Short .valueOf("1")); feeViewList.add(new FeeView(periodicFee)); FeeBO upfrontFee = TestObjectFactory.createOneTimeRateFee("Upfront Fee", FeeCategory.LOAN, Double.valueOf("20"),FeeFormula.AMOUNT, FeePayment.UPFRONT); feeViewList.add(new FeeView(upfrontFee)); accountBO=new LoanBO(TestObjectFactory.getUserContext(), loanOffering, group, AccountState.getStatus(Short.valueOf("5")), new Money("300.0"), Short.valueOf("6"),new Date(System.currentTimeMillis()),false,1.2,(short) 0, new Fund(),feeViewList); new TestObjectPersistence().persist(accountBO); assertEquals(6,accountBO.getAccountActionDates().size()); HibernateUtil.closeSession(); accountBO = (AccountBO) HibernateUtil.getSessionTL().get( AccountBO.class, accountBO.getAccountId()); accountBO.applyPayment(TestObjectFactory.getLoanAccountPaymentData( null, new Money("180.1"), accountBO.getCustomer(), accountBO .getPersonnel(), "432423", (short) 1, new Date(System .currentTimeMillis()), new Date(System .currentTimeMillis()))); HibernateUtil.commitTransaction(); HibernateUtil.closeSession(); accountBO = (AccountBO) HibernateUtil.getSessionTL().get( AccountBO.class, accountBO.getAccountId()); assertEquals(new Money(),((LoanBO) accountBO).getTotalPaymentDue()); LoanBO loanBO = (LoanBO) accountBO; UserContext uc = TestObjectFactory.getUserContext(); Money totalRepaymentAmount = loanBO.getTotalEarlyRepayAmount(); assertEquals(new Money("280.0"),totalRepaymentAmount); loanBO.makeEarlyRepayment(loanBO.getTotalEarlyRepayAmount(), null, null, "1", uc.getId()); HibernateUtil.commitTransaction(); HibernateUtil.closeSession(); accountBO = (AccountBO) HibernateUtil.getSessionTL().get( AccountBO.class, accountBO.getAccountId()); assertEquals(accountBO.getAccountState().getId(), new Short( AccountStates.LOANACC_OBLIGATIONSMET)); LoanSummaryEntity loanSummaryEntity = loanBO.getLoanSummary(); assertEquals(new Money(), loanSummaryEntity.getPrincipalDue() .add(loanSummaryEntity.getFeesDue()).add( loanSummaryEntity.getInterestDue()).add( loanSummaryEntity.getPenaltyDue())); assertEquals(2,accountBO.getAccountPayments().size()); AccountPaymentEntity accountPaymentEntity =(AccountPaymentEntity) Arrays.asList(accountBO.getAccountPayments().toArray()).get(0); assertEquals(6, accountPaymentEntity.getAccountTrxns().size()); for (AccountTrxnEntity accountTrxnEntity : accountPaymentEntity .getAccountTrxns()) { if(accountTrxnEntity.getInstallmentId().equals(Short.valueOf("6"))){ LoanTrxnDetailEntity loanTrxnDetailEntity = (LoanTrxnDetailEntity) accountTrxnEntity; assertEquals(new Money("45.5"), accountTrxnEntity.getAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getInterestAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getMiscFeeAmount()); assertEquals(new Money(), loanTrxnDetailEntity .getMiscPenaltyAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getPenaltyAmount()); assertEquals(4, accountTrxnEntity.getFinancialTransactions().size()); assertEquals(0, loanTrxnDetailEntity.getFeesTrxnDetails().size()); } else if(accountTrxnEntity.getInstallmentId().equals(Short.valueOf("1"))){ LoanTrxnDetailEntity loanTrxnDetailEntity = (LoanTrxnDetailEntity) accountTrxnEntity; assertEquals(new Money("30.9"), accountTrxnEntity.getAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getInterestAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getMiscFeeAmount()); assertEquals(new Money(), loanTrxnDetailEntity .getMiscPenaltyAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getPenaltyAmount()); assertEquals(2, accountTrxnEntity.getFinancialTransactions().size()); assertEquals(0, loanTrxnDetailEntity.getFeesTrxnDetails().size()); }else{ LoanTrxnDetailEntity loanTrxnDetailEntity = (LoanTrxnDetailEntity) accountTrxnEntity; assertEquals(new Money("50.9"), accountTrxnEntity.getAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getInterestAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getMiscFeeAmount()); assertEquals(new Money(), loanTrxnDetailEntity .getMiscPenaltyAmount()); assertEquals(new Money(), loanTrxnDetailEntity.getPenaltyAmount()); assertEquals(2, accountTrxnEntity.getFinancialTransactions().size()); assertEquals(0, loanTrxnDetailEntity.getFeesTrxnDetails().size()); } } } | 45468 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45468/8b7a0cdb79f363f8ac3f82d8f06e16d5166a08ed/TestLoanBO.java/clean/mifos/test/org/mifos/application/accounts/loan/business/TestLoanBO.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
6464,
41,
20279,
426,
9261,
1398,
1988,
6261,
16507,
350,
52,
1512,
625,
287,
1435,
1216,
1185,
288,
202,
202,
4667,
21747,
5315,
18721,
310,
273,
7766,
921,
1733,
18... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
6464,
41,
20279,
426,
9261,
1398,
1988,
6261,
16507,
350,
52,
1512,
625,
287,
1435,
1216,
1185,
288,
202,
202,
4667,
21747,
5315,
18721,
310,
273,
7766,
921,
1733,
18... |
if ( ++this.byeCount == NDIALOGS) { this.shutDown(); } | synchronized (this) { this.byeCount++; if (byeCount == NDIALOGS) { long current = System.currentTimeMillis(); long sec = (current - start) / 1000; System.out.println("Thrupt = " + NDIALOGS / sec); } } dialog.delete(); | public void processBye( Request request, ServerTransaction serverTransactionId) { try { if (serverTransactionId == null) { return; } Dialog dialog = serverTransactionId.getDialog(); Response response = messageFactory.createResponse (200, request); serverTransactionId.sendResponse(response); // so that the finalization method will run // and exit all resources. // handled both byes then shutdown Appdata appdata = (Appdata) dialog.getApplicationData(); appdata.cancelTimer(); if ( ++this.byeCount == NDIALOGS) { this.shutDown(); } } catch (Exception ex) { ex.printStackTrace(); System.exit(0); } } | 7607 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7607/d3bce65e49e71ee7df15bd72fd338535d4501bc1/Shootist.java/buggy/trunk/src/test/load/concurrency/Shootist.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
225,
918,
1207,
858,
73,
12,
202,
202,
691,
590,
16,
202,
202,
2081,
3342,
1438,
27387,
13,
288,
202,
202,
698,
288,
1082,
202,
430,
261,
3567,
27387,
422,
446,
13,
288,
950... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
225,
918,
1207,
858,
73,
12,
202,
202,
691,
590,
16,
202,
202,
2081,
3342,
1438,
27387,
13,
288,
202,
202,
698,
288,
1082,
202,
430,
261,
3567,
27387,
422,
446,
13,
288,
950... |
cluster = getUInt24(1 + lenlen); | cluster = getInt24(1 + lenlen); | public DataRun(NTFSNonResidentAttribute attr, int offset, long vcn, long previousLCN) { super(attr, offset); // read first byte in type attribute this.type = getUInt8(0); final int lenlen = type & 0xF; final int clusterlen = type >>> 4; this.size = lenlen + clusterlen + 1; this.vcn = vcn; switch (lenlen) { case 0x01: length = getUInt8(1); break; case 0x02: length = getUInt16(1); break; case 0x03: length = getUInt24(1); break; case 0x04: length = getUInt32AsInt(1); break; default: throw new IllegalArgumentException("Invalid length length " + lenlen); } final int cluster; switch (clusterlen) { case 0x01: cluster = getUInt8(1 + lenlen); break; case 0x02: cluster = getUInt16(1 + lenlen); break; case 0x03: cluster = getUInt24(1 + lenlen); break; case 0x04: cluster = getUInt32AsInt(1 + lenlen); break; default: throw new IllegalArgumentException("Unknown cluster length " + clusterlen); } this.cluster = cluster + previousLCN; } | 1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/49e58cfedb9c69fdd18e74b01bbd19bb0abde948/DataRun.java/buggy/fs/src/fs/org/jnode/fs/ntfs/DataRun.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1910,
1997,
12,
1784,
4931,
3989,
607,
6392,
1499,
1604,
16,
509,
1384,
16,
1525,
331,
10305,
16,
5411,
1525,
2416,
48,
12821,
13,
288,
3639,
2240,
12,
1747,
16,
1384,
1769,
3639,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1910,
1997,
12,
1784,
4931,
3989,
607,
6392,
1499,
1604,
16,
509,
1384,
16,
1525,
331,
10305,
16,
5411,
1525,
2416,
48,
12821,
13,
288,
3639,
2240,
12,
1747,
16,
1384,
1769,
3639,
... |
new NoViableAltException("136:48: ( \';\' )?", 11, 0, input); | new NoViableAltException("233:48: ( \';\' )?", 8, 0, input); | public void expander() throws RecognitionException { String name = null; String config=null; try { // C:\Projects\jboss-rules\drools-compiler\src\main\resources\org\drools\lang\drl.g:136:17: ( 'expander' (name= dotted_name )? ( ';' )? opt_eol ) // C:\Projects\jboss-rules\drools-compiler\src\main\resources\org\drools\lang\drl.g:136:17: 'expander' (name= dotted_name )? ( ';' )? opt_eol { match(input,18,FOLLOW_18_in_expander230); // C:\Projects\jboss-rules\drools-compiler\src\main\resources\org\drools\lang\drl.g:136:28: (name= dotted_name )? int alt10=2; int LA10_0 = input.LA(1); if ( LA10_0==ID ) { alt10=1; } else if ( LA10_0==-1||LA10_0==EOL||LA10_0==16||(LA10_0>=19 && LA10_0<=20)||LA10_0==26||LA10_0==28 ) { alt10=2; } else { NoViableAltException nvae = new NoViableAltException("136:28: (name= dotted_name )?", 10, 0, input); throw nvae; } switch (alt10) { case 1 : // C:\Projects\jboss-rules\drools-compiler\src\main\resources\org\drools\lang\drl.g:136:29: name= dotted_name { following.push(FOLLOW_dotted_name_in_expander235); name=dotted_name(); following.pop(); } break; } // C:\Projects\jboss-rules\drools-compiler\src\main\resources\org\drools\lang\drl.g:136:48: ( ';' )? int alt11=2; int LA11_0 = input.LA(1); if ( LA11_0==16 ) { alt11=1; } else if ( LA11_0==-1||LA11_0==EOL||(LA11_0>=19 && LA11_0<=20)||LA11_0==26||LA11_0==28 ) { alt11=2; } else { NoViableAltException nvae = new NoViableAltException("136:48: ( \';\' )?", 11, 0, input); throw nvae; } switch (alt11) { case 1 : // C:\Projects\jboss-rules\drools-compiler\src\main\resources\org\drools\lang\drl.g:136:48: ';' { match(input,16,FOLLOW_16_in_expander239); } break; } following.push(FOLLOW_opt_eol_in_expander242); opt_eol(); following.pop(); if (expanderResolver == null) throw new IllegalArgumentException("Unable to use expander. Make sure a expander or dsl config is being passed to the parser. [ExpanderResolver was not set]."); expander = expanderResolver.get( name, config ); } } catch (RecognitionException re) { reportError(re); recover(input,re); } finally { } return ; } | 5490 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5490/9c6423b7a31fdc4a1317e71a6d2850c94e2140e0/RuleParser.java/buggy/drools-compiler/src/main/java/org/drools/lang/RuleParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
4542,
264,
1435,
1216,
9539,
288,
6647,
514,
508,
273,
446,
31,
1171,
202,
202,
780,
642,
33,
2011,
31,
540,
202,
3639,
775,
288,
5411,
368,
385,
5581,
15298,
64,
10649,
8464... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4542,
264,
1435,
1216,
9539,
288,
6647,
514,
508,
273,
446,
31,
1171,
202,
202,
780,
642,
33,
2011,
31,
540,
202,
3639,
775,
288,
5411,
368,
385,
5581,
15298,
64,
10649,
8464... |
int [] result = new int[316]; | int [] result = new int[343]; | private static int [] zzUnpackAction() { int [] result = new int[316]; int offset = 0; offset = zzUnpackAction(ZZ_ACTION_PACKED_0, offset, result); return result; } | 45341 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45341/58e844dc77aa5d1ee9f4952f22f0f7b6b8469457/CSSTokenizerFilter.java/buggy/src/freenet/clients/http/filter/CSSTokenizerFilter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
760,
509,
5378,
11273,
23649,
1803,
1435,
288,
565,
509,
5378,
563,
273,
394,
509,
63,
5026,
23,
15533,
565,
509,
1384,
273,
374,
31,
565,
1384,
273,
11273,
23649,
1803,
12,
27096,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
760,
509,
5378,
11273,
23649,
1803,
1435,
288,
565,
509,
5378,
563,
273,
394,
509,
63,
5026,
23,
15533,
565,
509,
1384,
273,
374,
31,
565,
1384,
273,
11273,
23649,
1803,
12,
27096,
... |
String pname = pg_stream.ReceiveString(8192); | String pname = pg_stream.ReceiveString(receive_sbuf,8192,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); } } | 45672 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45672/f41dcbe4d810f0906f43d1b345cf506d72c792ac/Connection.java/buggy/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,
... |
public IResultIterator execute( ) throws DataException | public IResultIterator execute( IEventHandler eventHandler ) throws DataException | public IResultIterator execute( ) throws DataException { return new CachedResultSet( this, getOdaCacheResultSet( ).getResultClass( ), getOdaCacheResultSet( ) ); } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/83c61e18ec014b0a0d7683b4196d0a84fb37ac77/DataSourceQuery.java/clean/data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/executor/dscache/DataSourceQuery.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
467,
1253,
3198,
1836,
12,
262,
1216,
1910,
503,
202,
95,
202,
202,
2463,
394,
15771,
13198,
12,
333,
16,
9506,
202,
588,
51,
2414,
1649,
13198,
12,
262,
18,
588,
1253,
797,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
467,
1253,
3198,
1836,
12,
262,
1216,
1910,
503,
202,
95,
202,
202,
2463,
394,
15771,
13198,
12,
333,
16,
9506,
202,
588,
51,
2414,
1649,
13198,
12,
262,
18,
588,
1253,
797,
... |
(IProject) aProject)); | (IProject) aProject.getProject())); | private void getPBProject(IContainer aProject) { IFile aPBProject = aProject.getFile( new Path(IWOLipsPluginConstants.PROJECT_FILE_NAME)); File aFile = aPBProject.getLocation().toFile(); pbProject = null; fixEOModelerMacOSXBug(aFile); try { boolean sync = !aFile.exists(); pbProject = new PBProject( aFile, !ProjectHelper.isWOAppBuilderInstalled( (IProject) aProject)); if (sync) syncPBProjectWithProject(); } catch (Exception anException) { WOLipsPlugin.log(anException); } } | 50596 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50596/d534a64502ae1e8eae9b0e0806af6e349690d4ae/PBProjectUpdater.java/clean/src/wolips/java/org/objectstyle/wolips/project/PBProjectUpdater.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1689,
38,
4109,
12,
45,
2170,
279,
4109,
13,
288,
202,
202,
45,
812,
279,
20724,
4109,
273,
1082,
202,
69,
4109,
18,
29925,
12,
9506,
202,
2704,
2666,
12,
45,
59,
1741... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1689,
38,
4109,
12,
45,
2170,
279,
4109,
13,
288,
202,
202,
45,
812,
279,
20724,
4109,
273,
1082,
202,
69,
4109,
18,
29925,
12,
9506,
202,
2704,
2666,
12,
45,
59,
1741... |
packagePerspective.addRule(new GoOperationToCollaborationDiagram()); | /* Removed the next one due to issue 2165. packagePerspective.addRule(new GoOperationToCollaborationDiagram());*/ | public Collection getDefaultPerspectives() { ExplorerPerspective classPerspective = new ExplorerPerspective("combobox.item.class-centric"); classPerspective.addRule(new GoProjectToModel()); classPerspective.addRule(new GoNamespaceToClassifierAndPackage()); classPerspective.addRule(new GoNamespaceToDiagram()); classPerspective.addRule(new GoClassToSummary()); classPerspective.addRule(new GoSummaryToAssociation()); classPerspective.addRule(new GoSummaryToAttribute()); classPerspective.addRule(new GoSummaryToOperation()); classPerspective.addRule(new GoSummaryToInheritance()); classPerspective.addRule(new GoSummaryToIncomingDependency()); classPerspective.addRule(new GoSummaryToOutgoingDependency()); ExplorerPerspective packagePerspective = new ExplorerPerspective("combobox.item.package-centric"); packagePerspective.addRule(new GoProjectToModel()); packagePerspective.addRule(new GoNamespaceToOwnedElements()); packagePerspective.addRule(new GoNamespaceToDiagram()); packagePerspective.addRule(new GoUseCaseToExtensionPoint()); packagePerspective.addRule(new GoClassifierToStructuralFeature()); packagePerspective.addRule(new GoClassifierToBehavioralFeature()); packagePerspective.addRule(new GoCollaborationToInteraction()); packagePerspective.addRule(new GoInteractionToMessages()); packagePerspective.addRule(new GoMessageToAction()); packagePerspective.addRule(new GoSignalToReception()); packagePerspective.addRule(new GoLinkToStimuli()); packagePerspective.addRule(new GoStimulusToAction()); packagePerspective.addRule(new GoClassifierToCollaboration()); packagePerspective.addRule(new GoOperationToCollaboration()); packagePerspective.addRule(new GoOperationToCollaborationDiagram()); packagePerspective.addRule(new GoBehavioralFeatureToStateMachine()); packagePerspective.addRule(new GoBehavioralFeatureToStateDiagram()); // works for both statediagram as activitygraph packagePerspective.addRule(new GoStatemachineToDiagram()); packagePerspective.addRule(new GoStateMachineToState()); packagePerspective.addRule(new GoCompositeStateToSubvertex()); packagePerspective.addRule(new GoStateToInternalTrans()); packagePerspective.addRule(new GoStateToDoActivity()); packagePerspective.addRule(new GoStateToEntry()); packagePerspective.addRule(new GoStateToExit()); packagePerspective.addRule(new GoClassifierToSequenceDiagram()); packagePerspective.addRule(new GoOperationToSequenceDiagram()); packagePerspective.addRule(new GoClassifierToInstance()); packagePerspective.addRule(new GoStateToIncomingTrans()); packagePerspective.addRule(new GoStateToOutgoingTrans()); ExplorerPerspective diagramPerspective = new ExplorerPerspective("combobox.item.diagram-centric"); diagramPerspective.addRule(new GoProjectToModel()); diagramPerspective.addRule(new GoModelToDiagrams()); diagramPerspective.addRule(new GoDiagramToNode()); diagramPerspective.addRule(new GoDiagramToEdge()); diagramPerspective.addRule(new GoUseCaseToExtensionPoint()); diagramPerspective.addRule(new GoClassifierToStructuralFeature()); diagramPerspective.addRule(new GoClassifierToBehavioralFeature()); ExplorerPerspective inheritancePerspective = new ExplorerPerspective("combobox.item.inheritance-centric"); inheritancePerspective.addRule(new GoProjectToModel()); inheritancePerspective.addRule(new GoModelToBaseElements()); inheritancePerspective.addRule( new GoGeneralizableElementToSpecialized()); ExplorerPerspective associationsPerspective = new ExplorerPerspective("combobox.item.class-associations"); associationsPerspective.addRule(new GoProjectToModel()); associationsPerspective.addRule(new GoNamespaceToDiagram()); associationsPerspective.addRule(new GoPackageToClass()); associationsPerspective.addRule(new GoClassToAssociatedClass()); ExplorerPerspective statePerspective = new ExplorerPerspective("combobox.item.state-centric"); statePerspective.addRule(new GoProjectToStateMachine()); statePerspective.addRule(new GoStatemachineToDiagram()); statePerspective.addRule(new GoStateMachineToState()); statePerspective.addRule(new GoCompositeStateToSubvertex()); statePerspective.addRule(new GoStateToIncomingTrans()); statePerspective.addRule(new GoStateToOutgoingTrans()); ExplorerPerspective transitionsPerspective = new ExplorerPerspective("combobox.item.transitions-centric"); transitionsPerspective.addRule(new GoProjectToStateMachine()); transitionsPerspective.addRule(new GoStatemachineToDiagram()); transitionsPerspective.addRule(new GoStateMachineToTransition()); transitionsPerspective.addRule(new GoTransitionToSource()); transitionsPerspective.addRule(new GoTransitionToTarget()); Collection c = new ArrayList(); c.add(packagePerspective); c.add(classPerspective); c.add(diagramPerspective); c.add(inheritancePerspective); c.add(associationsPerspective); c.add(statePerspective); c.add(transitionsPerspective); return c; } | 7166 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7166/c907d531e1113f77da0c52fa194bb6f32da9ebdc/PerspectiveManager.java/buggy/src_new/org/argouml/ui/explorer/PerspectiveManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
2200,
4829,
14781,
1181,
3606,
1435,
288,
3639,
1312,
11766,
14781,
16772,
667,
14781,
16772,
273,
2398,
394,
1312,
11766,
14781,
16772,
2932,
9301,
27570,
18,
1726,
18,
1106,
17,
71,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2200,
4829,
14781,
1181,
3606,
1435,
288,
3639,
1312,
11766,
14781,
16772,
667,
14781,
16772,
273,
2398,
394,
1312,
11766,
14781,
16772,
2932,
9301,
27570,
18,
1726,
18,
1106,
17,
71,
... |
instance = constructor.newInstance(new Object[] {m_factory.getBundleContext()}); | instance = constructor.newInstance(new Object[] {this, m_factory.getBundleContext()}); | public Object createInstance() { if (!isLoaded()) { load(); } Object instance = null; try { Activator.getLogger().log(Level.INFO, "[" + m_metadata.getClassName() + "] createInstance -> call setComponentManager"); // Invoke the static method setComponentManager on the manipulated class Method method = m_clazz.getDeclaredMethod("setComponentManager", new Class[] {this.getClass()}); method.setAccessible(true); method.invoke(null, new Object[] {this}); Activator.getLogger().log(Level.INFO, "[" + m_metadata.getClassName() + "] createInstance -> Try to find the constructor"); // Try to find if there is a constructor with a bundle context as parameter : try { Constructor constructor = m_clazz.getConstructor(new Class[] {BundleContext.class}); constructor.setAccessible(true); instance = constructor.newInstance(new Object[] {m_factory.getBundleContext()}); } catch (NoSuchMethodException e) { Activator.getLogger().log(Level.INFO, "[" + m_metadata.getClassName() + "] createInstance -> No constructor with a bundle context"); } // Create an instance if no instance are already created with <init>()BundleContext Activator.getLogger().log(Level.INFO, "[" + m_metadata.getClassName() + "] createInstance -> Try to create the object with an empty constructor"); if (instance == null) { instance = m_clazz.newInstance(); } } catch (InstantiationException e) { Activator.getLogger().log(Level.SEVERE, "[" + m_metadata.getClassName() + "] createInstance -> The Component Instance cannot be instancied : " + e.getMessage()); e.printStackTrace(); } catch (IllegalAccessException e) { Activator.getLogger().log(Level.SEVERE, "[" + m_metadata.getClassName() + "] createInstance -> The Component Instance is not accessible : " + e.getMessage()); e.printStackTrace(); } catch (SecurityException e) { Activator.getLogger().log(Level.SEVERE, "[" + m_metadata.getClassName() + "] createInstance -> The Component Instance is not accessible (security reason) : " + e.getMessage()); e.printStackTrace(); } catch (IllegalArgumentException e) { Activator.getLogger().log(Level.SEVERE, "[" + m_metadata.getClassName() + "] createInstance -> Cannot invoke the setComponentManager method (illegal argument) : " + e.getMessage()); e.printStackTrace(); } catch (InvocationTargetException e) { Activator.getLogger().log(Level.SEVERE, "[" + m_metadata.getClassName() + "] createInstance -> Cannot invoke the setComponentManager method (illegal target) : " + e.getMessage()); e.printStackTrace(); } catch (NoSuchMethodException e) { Activator.getLogger().log(Level.SEVERE, "[" + m_metadata.getClassName() + "] createInstance -> Cannot invoke the setComponentManager method (method not found) : " + e.getMessage()); e.printStackTrace(); } Activator.getLogger().log(Level.INFO, "[" + m_metadata.getClassName() + "] createInstance -> Return the instance " + instance); // Register the new instance addInstance(instance); return instance; } | 45948 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45948/829905b8fe2a180340e944b50e59cc3e5a0a0f00/ComponentManager.java/clean/org.apache.felix.ipojo/src/main/java/org/apache/felix/ipojo/ComponentManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1033,
20075,
1435,
288,
202,
202,
430,
16051,
291,
8835,
10756,
288,
1262,
5621,
289,
202,
202,
921,
791,
273,
446,
31,
202,
202,
698,
288,
1082,
202,
12241,
639,
18,
588,
332... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1033,
20075,
1435,
288,
202,
202,
430,
16051,
291,
8835,
10756,
288,
1262,
5621,
289,
202,
202,
921,
791,
273,
446,
31,
202,
202,
698,
288,
1082,
202,
12241,
639,
18,
588,
332... |
if (from < 0 || from > to) throw new IndexOutOfBoundsException(); if (from == to) return; int lo_offset = from >>> 6; int hi_offset = to >>> 6; ensure(hi_offset); if (lo_offset == hi_offset) { bits[hi_offset] |= (-1L << from) & ((1L << to) - 1); return; } bits[lo_offset] |= -1L << from; bits[hi_offset] |= (1L << to) - 1; for (int i = lo_offset + 1; i < hi_offset; i++) bits[i] = -1; | int offset = pos >> 6; ensure(offset); bits[offset] |= 1L << pos; | public void set(int from, int to) { if (from < 0 || from > to) throw new IndexOutOfBoundsException(); if (from == to) return; int lo_offset = from >>> 6; int hi_offset = to >>> 6; ensure(hi_offset); if (lo_offset == hi_offset) { bits[hi_offset] |= (-1L << from) & ((1L << to) - 1); return; } bits[lo_offset] |= -1L << from; bits[hi_offset] |= (1L << to) - 1; for (int i = lo_offset + 1; i < hi_offset; i++) bits[i] = -1; } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/03ccc48ad99f370100d28d05282f5ecf9aba8ad6/BitSet.java/buggy/core/src/classpath/5.0/java/util/BitSet.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
444,
12,
474,
628,
16,
509,
358,
13,
225,
288,
565,
309,
261,
2080,
411,
374,
747,
628,
405,
358,
13,
1377,
604,
394,
17768,
5621,
565,
309,
261,
2080,
422,
358,
13,
1377,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
444,
12,
474,
628,
16,
509,
358,
13,
225,
288,
565,
309,
261,
2080,
411,
374,
747,
628,
405,
358,
13,
1377,
604,
394,
17768,
5621,
565,
309,
261,
2080,
422,
358,
13,
1377,
... |
return BugzillaPlugin.getRepositoryConfiguration(repositoryUrl, proxySettings, userName, password, encoding) | return BugzillaPlugin.getRepositoryConfiguration(true, repositoryUrl, proxySettings, userName, password, encoding) | public static List<String> getProductList(String repositoryUrl, Proxy proxySettings, String userName, String password, String encoding) throws IOException, LoginException, Exception { return BugzillaPlugin.getRepositoryConfiguration(repositoryUrl, proxySettings, userName, password, encoding) .getProducts(); // BugzillaQueryPageParser parser = new // BugzillaQueryPageParser(repository, new NullProgressMonitor()); // if (!parser.wasSuccessful()) { // throw new RuntimeException("Couldn't get products"); // } else { // return Arrays.asList(parser.getProductValues()); // } } | 51151 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51151/870bef936f9d2d5a7188ca7b829b13efb90c18a6/BugzillaRepositoryUtil.java/buggy/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/BugzillaRepositoryUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
987,
32,
780,
34,
15880,
682,
12,
780,
3352,
1489,
16,
7659,
2889,
2628,
16,
514,
12065,
16,
514,
2201,
16,
514,
2688,
13,
1082,
202,
15069,
1860,
16,
11744,
503,
16,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
987,
32,
780,
34,
15880,
682,
12,
780,
3352,
1489,
16,
7659,
2889,
2628,
16,
514,
12065,
16,
514,
2201,
16,
514,
2688,
13,
1082,
202,
15069,
1860,
16,
11744,
503,
16,
1... |
if (i[j] < 0 || i[j] > 255) | if ((i[j] < 0) || (i[j] > 255)) | public static boolean checkAddress(int[] i) { // ip address (IPV6 is not supported by this transport) boolean logDEBUG = Logger.shouldLog(Logger.DEBUG,IPUtil.class); if(logDEBUG) Logger.debug(IPUtil.class, "Checking "+i[0]+"."+i[1]+"."+i[2]+ "."+i[3]); if (i.length != 4) return false; for (int j = 0 ; j < 4 ; j++) if (i[j] < 0 || i[j] > 255) return false; if (i[0] == 10 || (i[0] == 172 && i[1] >= 16 && i[1] < 31) || (i[0] == 192 && i[1] == 168)) // local network return false; if (i[0] == 169 && i[1] == 254) return false; // link local if (i[0] == 198 && (i[1] == 18 || i[1] == 19)) return false; // RFC2544 if (i[0] == 192 && i[1] == 0 && i[2] == 2) return false; // test-net, see RFC3330 if (i[0] == 127) // loopback return false; if (i[0] == 0) // "this" net return false; if (i[0] >= 224 && i[0] < 240) return false; // multicast return true; } | 56348 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56348/ca136843ae9ecb30cadada58a33a5dc2cf8ad064/IPUtil.java/buggy/src/freenet/transport/IPUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1250,
866,
1887,
12,
474,
8526,
277,
13,
288,
202,
759,
2359,
1758,
261,
28026,
26,
353,
486,
3260,
635,
333,
4736,
13,
202,
6494,
613,
9394,
273,
4242,
18,
13139,
1343,
12,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1250,
866,
1887,
12,
474,
8526,
277,
13,
288,
202,
759,
2359,
1758,
261,
28026,
26,
353,
486,
3260,
635,
333,
4736,
13,
202,
6494,
613,
9394,
273,
4242,
18,
13139,
1343,
12,
... |
IModuleResource[] mr = getMembers(cont[i], Path.EMPTY, javaPath, javaCont); | IModuleResource[] mr = getMembers(javaCont[i], javaPath, javaPath, javaCont); | public IModuleResource[] members() throws CoreException { members.clear(); IPath javaPath = Path.EMPTY; if (J2EEProjectUtilities.isDynamicWebProject(component.getProject())) javaPath = WEB_CLASSES_PATH; IContainer[] cont = getResourceFolders(); IContainer[] javaCont = getJavaOutputFolders(); if (javaPath.isEmpty()) { IContainer[] cont2 = new IContainer[cont.length + javaCont.length]; System.arraycopy(cont, 0, cont2, 0, cont.length); System.arraycopy(javaCont, 0, cont2, cont.length, javaCont.length); cont = cont2; javaCont = null; javaPath = null; } int size = cont.length; for (int i = 0; i < size; i++) { IModuleResource[] mr = getMembers(cont[i], Path.EMPTY, javaPath, javaCont); int size2 = mr.length; for (int j = 0; j < size2; j++) { if (!members.contains(mr[j])) members.add(mr[j]); } } IModuleResource[] mr = new IModuleResource[members.size()]; members.toArray(mr); return mr; } | 8196 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8196/d8f49028c58922c771c758309cb37567f2af3394/J2EEFlexProjDeployable.java/clean/plugins/org.eclipse.jst.j2ee/j2eeplugin/org/eclipse/jst/j2ee/internal/deployables/J2EEFlexProjDeployable.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
467,
3120,
1420,
8526,
4833,
1435,
1216,
30015,
288,
202,
202,
7640,
18,
8507,
5621,
202,
202,
45,
743,
2252,
743,
273,
2666,
18,
13625,
31,
202,
202,
430,
261,
46,
22,
9383,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3120,
1420,
8526,
4833,
1435,
1216,
30015,
288,
202,
202,
7640,
18,
8507,
5621,
202,
202,
45,
743,
2252,
743,
273,
2666,
18,
13625,
31,
202,
202,
430,
261,
46,
22,
9383,
... |
sb.append(offset >= 0 ? '+' : '-'); | private String getDefaultDisplayName(boolean dst) { int offset = getRawOffset(); if (dst && this instanceof SimpleTimeZone) { // ugly, but this is a design failure of the API: // getDisplayName takes a dst parameter even though // TimeZone knows nothing about daylight saving offsets. offset += ((SimpleTimeZone) this).getDSTSavings(); } StringBuffer sb = new StringBuffer(9); sb.append("GMT"); sb.append(offset >= 0 ? '+' : '-'); offset = Math.abs(offset) / (1000 * 60); int hours = offset / 60; int minutes = offset % 60; sb.append((char) ('0' + hours / 10)).append((char) ('0' + hours % 10)); sb.append(':'); sb.append((char) ('0' + minutes / 10)).append((char) ('0' + minutes % 10)); return sb.toString(); } | 1739 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1739/364499cac845fc38bebb2ed1c94a0b49eea79a0c/TimeZone.java/clean/libjava/java/util/TimeZone.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
514,
4829,
20524,
12,
6494,
3046,
13,
225,
288,
565,
509,
1384,
273,
10547,
2335,
5621,
565,
309,
261,
11057,
597,
333,
1276,
4477,
16760,
13,
1377,
288,
202,
759,
26920,
16,
1496,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4829,
20524,
12,
6494,
3046,
13,
225,
288,
565,
509,
1384,
273,
10547,
2335,
5621,
565,
309,
261,
11057,
597,
333,
1276,
4477,
16760,
13,
1377,
288,
202,
759,
26920,
16,
1496,
... | |
case NORMAL: combineTwoItems(); break; | case NORMAL: combineTwoItems(); break; | public void run() { switch ( searchType ) { case NORMAL: combineTwoItems(); break; case GNOMES: combineThreeItems(); break; } } | 50364 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50364/eb8203b0add11024f00f9d7ed2ad7b2b63269aab/ItemManageFrame.java/clean/src/net/sourceforge/kolmafia/ItemManageFrame.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1875,
202,
482,
918,
1086,
1435,
1082,
202,
95,
9506,
202,
9610,
261,
1623,
559,
262,
9506,
202,
95,
6862,
202,
3593,
16362,
30,
25083,
202,
14082,
11710,
3126,
5621,
25083,
202,
8820,
31,
686... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
482,
918,
1086,
1435,
1082,
202,
95,
9506,
202,
9610,
261,
1623,
559,
262,
9506,
202,
95,
6862,
202,
3593,
16362,
30,
25083,
202,
14082,
11710,
3126,
5621,
25083,
202,
8820,
31,
686... |
PyType self_type = getType(); PyObject impl = self_type.lookup("__floordiv__"); if (impl != null) { PyObject res = impl.__get__(this, self_type).__call__(other); if (res == Py.NotImplemented) | PyType self_type=getType(); PyObject impl=self_type.lookup("__floordiv__"); if (impl!=null) { PyObject res=impl.__get__(this,self_type).__call__(other); if (res==Py.NotImplemented) | public PyObject __floordiv__(PyObject other) { PyType self_type = getType(); PyObject impl = self_type.lookup("__floordiv__"); if (impl != null) { PyObject res = impl.__get__(this, self_type).__call__(other); if (res == Py.NotImplemented) return null; return res; } return super.__floordiv__(other); } | 6527 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6527/f9070a6bddff5a2a46bf38e7d12db571f23826e9/PyDictionaryDerived.java/buggy/src/org/python/core/PyDictionaryDerived.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
4707,
921,
1001,
74,
383,
517,
427,
972,
12,
9413,
921,
1308,
13,
288,
3639,
4707,
559,
365,
67,
723,
273,
3130,
5621,
3639,
4707,
921,
9380,
273,
365,
67,
723,
18,
8664,
2932,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
4707,
921,
1001,
74,
383,
517,
427,
972,
12,
9413,
921,
1308,
13,
288,
3639,
4707,
559,
365,
67,
723,
273,
3130,
5621,
3639,
4707,
921,
9380,
273,
365,
67,
723,
18,
8664,
2932,
... |
clearListButton = new JButton("Liste lschen"); clearListButton.setToolTipText("Lsche gesamte Liste"); clearListButton.setActionCommand("clear_list"); clearListButton.addActionListener(this); clearListButton.setIcon(getImage("clearList.png")); clearListButton.setFocusPainted(false); toolBar.add(clearListButton); toolBar.addSeparator(); clearEntryButton = new JButton("Eintrge lschen"); clearEntryButton.setToolTipText("Lsche gewhlte Eintrge"); clearEntryButton.setActionCommand("clear_entry"); clearEntryButton.addActionListener(this); clearEntryButton.setIcon(getImage("delete.png")); clearEntryButton.setFocusPainted(false); toolBar.add(clearEntryButton); | deleteEntriesButton = new JButton(); deleteEntriesButton.setToolTipText(JFritz.getMessage("delete_entries")); deleteEntriesButton.setActionCommand("delete_entry"); deleteEntriesButton.addActionListener(this); deleteEntriesButton.setIcon(getImage("delete.png")); deleteEntriesButton.setFocusPainted(false); deleteEntriesButton.setEnabled(false); toolBar.add(deleteEntriesButton); | public JToolBar createCallerListToolBar() { JToolBar toolBar = new JToolBar(); toolBar.setFloatable(true); JToggleButton tb = new JToggleButton(getImage("callin_grey.png"), true); tb.setSelectedIcon(getImage("callin.png")); tb.setActionCommand("filter_callin"); tb.addActionListener(this); tb.setToolTipText(JFritz.getMessage("filter_callin")); tb.setSelected(!JFritzUtils.parseBoolean(JFritz.getProperty( "filter.callin", "false"))); toolBar.add(tb); tb = new JToggleButton(getImage("callinfailed_grey.png"), true); tb.setSelectedIcon(getImage("callinfailed.png")); tb.setActionCommand("filter_callinfailed"); tb.addActionListener(this); tb.setToolTipText(JFritz.getMessage("filter_callinfailed")); tb.setSelected(!JFritzUtils.parseBoolean(JFritz.getProperty( "filter.callinfailed", "false"))); toolBar.add(tb); tb = new JToggleButton(getImage("callout_grey.png"), true); tb.setSelectedIcon(getImage("callout.png")); tb.setActionCommand("filter_callout"); tb.addActionListener(this); tb.setToolTipText(JFritz.getMessage("filter_callout")); tb.setSelected(!JFritzUtils.parseBoolean(JFritz.getProperty( "filter.callout", "false"))); toolBar.add(tb); tb = new JToggleButton(getImage("phone_grey.png"), true); tb.setSelectedIcon(getImage("phone.png")); tb.setActionCommand("filter_number"); tb.addActionListener(this); tb.setToolTipText(JFritz.getMessage("filter_number")); tb.setSelected(!JFritzUtils.parseBoolean(JFritz.getProperty( "filter.number", "false"))); toolBar.add(tb); tb = new JToggleButton(getImage("handy_grey.png"), true); tb.setSelectedIcon(getImage("handy.png")); tb.setActionCommand("filter_handy"); tb.addActionListener(this); tb.setToolTipText(JFritz.getMessage("filter_handy")); tb.setSelected(!JFritzUtils.parseBoolean(JFritz.getProperty( "filter.handy", "false"))); toolBar.add(tb); dateButton = new JToggleButton(getImage("calendar_grey.png"), true); dateButton.setSelectedIcon(getImage("calendar.png")); dateButton.setActionCommand("filter_date"); dateButton.addActionListener(this); dateButton.setToolTipText(JFritz.getMessage("filter_date")); dateButton.setSelected(!JFritzUtils.parseBoolean(JFritz.getProperty( "filter.date", "false"))); setDateFilterText(); toolBar.add(dateButton); toolBar.addSeparator(); toolBar.addSeparator(); clearListButton = new JButton("Liste lschen"); clearListButton.setToolTipText("Lsche gesamte Liste"); clearListButton.setActionCommand("clear_list"); clearListButton.addActionListener(this); clearListButton.setIcon(getImage("clearList.png")); clearListButton.setFocusPainted(false); toolBar.add(clearListButton); toolBar.addSeparator(); clearEntryButton = new JButton("Eintrge lschen"); clearEntryButton.setToolTipText("Lsche gewhlte Eintrge"); clearEntryButton.setActionCommand("clear_entry"); clearEntryButton.addActionListener(this); clearEntryButton.setIcon(getImage("delete.png")); clearEntryButton.setFocusPainted(false); toolBar.add(clearEntryButton); toolBar.addSeparator(); toolBar.add(new JLabel(JFritz.getMessage("search") + ": ")); searchFilter = new JTextField(JFritz.getProperty("filter.search", ""), 10); searchFilter.addCaretListener(this); searchFilter.addCaretListener(new CaretListener() { String filter = ""; public void caretUpdate(CaretEvent e) { JTextField search = (JTextField) e.getSource(); if (!filter.equals(search.getText())) { filter = search.getText(); JFritz.setProperty("filter.search", filter); jfritz.getCallerlist().updateFilter(); jfritz.getCallerlist().fireTableStructureChanged(); } } }); toolBar.add(searchFilter); JButton button = new JButton(JFritz.getMessage("clear")); button.setActionCommand("clearSearchFilter"); button.addActionListener(this); toolBar.add(button); return toolBar; } | 7476 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7476/58d88520731c727859eb8c83445c1b6a03c1d6c6/CallerListPanel.java/clean/jfritz/src/de/moonflower/jfritz/callerlist/CallerListPanel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
804,
6364,
5190,
752,
11095,
682,
6364,
5190,
1435,
288,
202,
202,
46,
6364,
5190,
5226,
5190,
273,
394,
804,
6364,
5190,
5621,
202,
202,
6738,
5190,
18,
542,
4723,
429,
12,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
804,
6364,
5190,
752,
11095,
682,
6364,
5190,
1435,
288,
202,
202,
46,
6364,
5190,
5226,
5190,
273,
394,
804,
6364,
5190,
5621,
202,
202,
6738,
5190,
18,
542,
4723,
429,
12,
3... |
public void save(String id, Image image, boolean last) throws FormatException, IOException { if (tools == null) { tools = new LegacyQTTools(); r = tools.getUniverse(); } if (tools.isQTExpired()) { throw new FormatException(LegacyQTTools.EXPIRED_QT_MSG); } if (!tools.canDoQT()) throw new FormatException(LegacyQTTools.NO_QT_MSG); if (!id.equals(currentId)) { currentId = id; try { r.exec("QTSession.open()"); BufferedImage img = ImageTools.makeBuffered(image); width = img.getWidth(); height = img.getHeight(); File f = new File(id); r.setVar("f", f); r.setVar("width", (float) width); r.setVar("height", (float) height); r.exec("movFile = new QTFile(f)"); r.setVar("val", -2147483648 | 268435456); r.setVar("kMoviePlayer", 1414942532); r.exec("movie = Movie.createMovieFile(movFile, kMoviePlayer, val)"); int timeScale = TIME_SCALE; r.setVar("timeScale", timeScale); r.setVar("zero", 0); r.setVar("zeroFloat", (float) 0); r.exec("videoTrack = movie.addTrack(width, height, zeroFloat)"); r.exec("videoMedia = new VideoMedia(videoTrack, timeScale)"); r.exec("videoMedia.beginEdits()"); r.setVar("pixelFormat", 32); r.exec("imgDesc2 = new ImageDescription(pixelFormat)"); r.setVar("width", width); r.setVar("height", height); r.exec("imgDesc2.setWidth(width)"); r.exec("imgDesc2.setHeight(height)"); r.exec("gw = new QDGraphics(imgDesc2, zero)"); r.exec("bounds = new QDRect(zero, zero, width, height)"); r.exec("pixMap = gw.getPixMap()"); r.exec("pixSize = pixMap.getPixelSize()"); r.setVar("codec", codecID); r.setVar("quality", qualityID); int rawImageSize = width * height * 4; r.setVar("rawImageSize", rawImageSize); r.setVar("boolTrue", true); r.exec("imageHandle = new QTHandle(rawImageSize, boolTrue)"); r.exec("imageHandle.lock()"); r.exec("compressedImage = RawEncodedImage.fromQTHandle(imageHandle)"); // writer won't work without something to this effect: //r.exec("bestFidelity = CodecComponent.bestFidelity"); // however, every attempt at producing this fails miserably r.setVar("rate", 30); r.setVar("nullObj", null); r.exec("seq = new CSequence(gw, bounds, pixSize, codec, bestFidelity," + " quality, quality, rate, nullObj, zero)"); r.exec("imgDesc = seq.getDescription()"); } catch (Exception e) { e.printStackTrace(); throw new FormatException("Legacy QuickTime writer failed."); } } numWritten++; try { r.exec("pixMap = gw.getPixMap()"); r.exec("pixelData = pixMap.getPixelData()"); r.exec("intsPerRow = pixelData.getRowBytes()"); int intsPerRow = ((Integer) r.getVar("intsPerRow")).intValue() / 4; byte[][] px = ImageTools.getBytes(ImageTools.makeBuffered(image)); int[] pixels = new int[px[0].length]; for (int i=0; i<pixels.length; i++) { byte[] b = new byte[4]; for (int j=0; j<px.length; j++) { b[j] = px[j][i]; } for (int j=px.length; j<4; j++) { b[j] = px[j % px.length][i]; } pixels[i] = DataTools.bytesToInt(b, true); } if (pixels2 == null) pixels2 = new int[intsPerRow * height]; r.exec("nativeLittle = EndianOrder.isNativeLittleEndian()"); boolean nativeLittle = ((Boolean) r.getVar("nativeLittle")).booleanValue(); if (nativeLittle) { int offset1, offset2; for (int y=0; y<height; y++) { offset1 = y * width; offset2 = y * intsPerRow; for (int x=0; x<width; x++) { r.setVar("thisByte", pixels[offset1++]); r.exec("b = EndianOrder.flipBigEndianToNative32(thisByte)"); byte b = ((Byte) r.getVar("b")).byteValue(); pixels2[offset2++] = b; } } } else { for (int i=0; i<height; i++) { System.arraycopy(pixels, i*width, pixels2, i*intsPerRow, width); } } r.setVar("pixels2", pixels2); r.setVar("len", intsPerRow * height); r.exec("pixelData.copyFromArray(zero, pixels2, zero, len)"); r.setVar("four", 4); r.exec("cfInfo = seq.compressFrame(gw, bounds, four, compressedImage)"); // see developer.apple.com/qa/qtmcc/qtmcc20.html r.exec("similarity = cfInfo.getSimilarity()"); int sim = ((Integer) r.getVar("similarity")).intValue(); r.setVar("syncSample", sim == 0); r.exec("dataSize = cfInfo.getDataSize()"); r.setVar("fps", fps); r.setVar("frameRate", 600); r.setVar("rate", 600 / fps); boolean sync = ((Boolean) r.getVar("syncSample")).booleanValue(); int syncSample = sync ? 0 : 1; r.setVar("sync", syncSample); r.setVar("one", 1); r.exec("videoMedia.addSample(imageHandle, zero, dataSize, " + "rate, imgDesc, one, sync)"); } catch (Exception e) { e.printStackTrace(); throw new FormatException("Legacy QuickTime writer failed."); } if (last) { try { r.exec("videoMedia.endEdits()"); r.exec("duration = videoMedia.getDuration()"); r.setVar("floatOne", (float) 1.0); r.exec("videoTrack.insertMedia(zero, zero, duration, floatOne)"); r.exec("omf = OpenMovieFile.asWrite(movFile)"); r.exec("name = movFile.getName()"); r.setVar("minusOne", -1); r.exec("movie.addResource(omf, minusOne, name)"); r.exec("QTSession.close()"); } catch (Exception e) { e.printStackTrace(); throw new FormatException("Legacy QuickTime writer failed."); } } } | 46826 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46826/f8fea5aec2de454fd84e68759019ac47d99be52a/LegacyQTWriter.java/clean/loci/formats/LegacyQTWriter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
1923,
12,
780,
612,
16,
3421,
1316,
16,
1250,
1142,
13,
565,
1216,
4077,
503,
16,
1860,
225,
288,
565,
309,
261,
6642,
422,
446,
13,
288,
1377,
8513,
273,
394,
22781,
53,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
1923,
12,
780,
612,
16,
3421,
1316,
16,
1250,
1142,
13,
565,
1216,
4077,
503,
16,
1860,
225,
288,
565,
309,
261,
6642,
422,
446,
13,
288,
1377,
8513,
273,
394,
22781,
53,
5... | ||
pushByLocal(dbc, dbc.getRegisterOperand()); | pushByLocalObjectLoad(dbc, dbc.getRegisterOperand()); | public void sawOpcode(DismantleBytecode dbc, int seen) { int register; JavaClass cls; String signature; Item it, it2, it3; Constant cons; try { //It would be nice to also track field values, but this currently isn't done. //It would also be nice to track array values, but this currently isn't done. switch (seen) { case ALOAD: pushByLocal(dbc, dbc.getRegisterOperand()); break; case ALOAD_0: case ALOAD_1: case ALOAD_2: case ALOAD_3: pushByLocal(dbc, seen - ALOAD_0); break; case DLOAD: case DLOAD_0: case DLOAD_1: case DLOAD_2: case DLOAD_3: push(new Item("D")); break; case LLOAD: case LLOAD_0: case LLOAD_1: case LLOAD_2: case LLOAD_3: push(new Item("L")); break; case FLOAD: case FLOAD_0: case FLOAD_1: case FLOAD_2: case FLOAD_3: push(new Item("F")); break; case GETSTATIC: pushBySignature(dbc.getSigConstantOperand()); break; case LDC: case LDC_W: case LDC2_W: cons = dbc.getConstantRefOperand(); pushByConstant(dbc, cons); break; case INSTANCEOF: pop(); push(new Item("I")); break; case ARETURN: case ASTORE: case ASTORE_0: case ASTORE_1: case ASTORE_2: case ASTORE_3: case DRETURN: case DSTORE: case DSTORE_0: case DSTORE_1: case DSTORE_2: case DSTORE_3: case FRETURN: case FSTORE: case FSTORE_0: case FSTORE_1: case FSTORE_2: case FSTORE_3: case IFEQ: case IFNE: case IFLT: case IFLE: case IFGT: case IFGE: case IFNONNULL: case IFNULL: case IRETURN: case LOOKUPSWITCH: case LRETURN: case LSTORE: case LSTORE_0: case LSTORE_1: case LSTORE_2: case LSTORE_3: case MONITORENTER: case MONITOREXIT: case POP: case PUTSTATIC: case TABLESWITCH: pop(); break; case IF_ACMPEQ: case IF_ACMPNE: case IF_ICMPEQ: case IF_ICMPNE: case IF_ICMPLT: case IF_ICMPLE: case IF_ICMPGT: case IF_ICMPGE: case POP2: case PUTFIELD: pop(2); break; case IALOAD: case SALOAD: pop(2); push(new Item("I")); break; case DUP: it = pop(); push(it); push(it); break; case DUP2: it = pop(); it2 = pop(); push(it2); push(it); push(it2); push(it); break; case DUP_X1: it = pop(); it2 = pop(); push(it); push(it2); push(it); break; case DUP_X2: it = pop(); it2 = pop(); signature = it2.getSignature(); if (signature.equals("J") || signature.equals("D")) { push(it); push(it2); push(it); } else { it3 = pop(); push(it); push(it3); push(it2); push(it); } break; case DUP2_X1: it = pop(); it2 = pop(); signature = it.getSignature(); if (signature.equals("J") || signature.equals("D")) { push(it); push(it2); push(it); } else { it3 = pop(); push(it2); push(it); push(it3); push(it2); push(it); } break; case ATHROW: case CHECKCAST: case GOTO: case GOTO_W: case IINC: case NOP: case RET: case RETURN: break; case SWAP: Item i1 = pop(); Item i2 = pop(); push(i1); push(i2); break; case ICONST_M1: case ICONST_0: case ICONST_1: case ICONST_2: case ICONST_3: case ICONST_4: case ICONST_5: push(new Item("I", new Integer(seen-ICONST_0))); break; case LCONST_0: case LCONST_1: push(new Item("J", new Long(seen-LCONST_0))); break; case DCONST_0: case DCONST_1: push(new Item("D", new Double(seen-DCONST_0))); break; case FCONST_0: case FCONST_1: case FCONST_2: push(new Item("F", new Float(seen-FCONST_0))); break; case ACONST_NULL: push(new Item()); break; case ILOAD: case ILOAD_0: case ILOAD_1: case ILOAD_2: case ILOAD_3: if (seen == ILOAD) register = dbc.getRegisterOperand(); else register = seen - ILOAD_0; it = getLVValue(register); if (it == null) push(new Item("I")); else push(it); break; case ISTORE: case ISTORE_0: case ISTORE_1: case ISTORE_2: case ISTORE_3: it = pop(); if (seen == ILOAD) register = dbc.getRegisterOperand(); else register = seen - ISTORE_0; setLVValue( register, it ); break; case GETFIELD: pop(); push(new Item(dbc.getSigConstantOperand())); break; case ARRAYLENGTH: pop(); push(new Item("I")); break; case BALOAD: case CALOAD: pop(2); push(new Item("I")); break; case DALOAD: pop(2); push(new Item("D")); break; case FALOAD: pop(2); push(new Item("F")); break; case LALOAD: pop(2); push(new Item("J")); break; case AASTORE: case BASTORE: case CASTORE: case DASTORE: case FASTORE: case IASTORE: case LASTORE: case SASTORE: pop(3); break; case BIPUSH: case SIPUSH: push(new Item("I", new Integer((int)dbc.getIntConstant()))); break; case IADD: case ISUB: case IMUL: case IDIV: case IAND: case IOR: case IXOR: case ISHL: case ISHR: case IREM: case IUSHR: it = pop(); it2 = pop(); pushByIntMath(seen, it, it2); break; case INEG: it = pop(); if (it.getConstant() != null) { push(new Item("I", new Integer(-((Integer)it.getConstant()).intValue()))); } else { push(new Item("I")); } break; case LNEG: it = pop(); if (it.getConstant() != null) { push(new Item("J", new Long(-((Long)it.getConstant()).longValue()))); } else { push(new Item("J")); } break; case DNEG: it = pop(); if (it.getConstant() != null) { push(new Item("D", new Double(-((Double)it.getConstant()).doubleValue()))); } else { push(new Item("D")); } break; case LADD: case LSUB: case LMUL: case LDIV: case LAND: case LOR: case LXOR: case LSHL: case LSHR: case LREM: case LUSHR: it = pop(); it2 = pop(); pushByLongMath(seen, it, it2); break; case LCMP: it = pop(); it2 = pop(); if ((it.getConstant() != null) && it2.getConstant() != null) { long l = ((Long)it.getConstant()).longValue(); long l2 = ((Long)it.getConstant()).longValue(); if (l2 < l) push(new Item("I", new Integer(-1))); else if (l2 > l) push(new Item("I", new Integer(1))); else push(new Item("I", new Integer(0))); } else { push(new Item("I")); } break; case FCMPG: case FCMPL: it = pop(); it2 = pop(); if ((it.getConstant() != null) && it2.getConstant() != null) { float f = ((Float)it.getConstant()).floatValue(); float f2 = ((Float)it.getConstant()).floatValue(); if (f2 < f) push(new Item("I", new Integer(-1))); else if (f2 > f) push(new Item("I", new Integer(1))); else push(new Item("I", new Integer(0))); } else { push(new Item("I")); } break; case DCMPG: case DCMPL: it = pop(); it2 = pop(); if ((it.getConstant() != null) && it2.getConstant() != null) { double d = ((Double)it.getConstant()).doubleValue(); double d2 = ((Double)it.getConstant()).doubleValue(); if (d2 < d) push(new Item("I", new Integer(-1))); else if (d2 > d) push(new Item("I", new Integer(1))); else push(new Item("I", new Integer(0))); } else { push(new Item("I")); } break; case FADD: case FSUB: case FMUL: case FDIV: it = pop(); it2 = pop(); pushByFloatMath(seen, it, it2); break; case DADD: case DSUB: case DMUL: case DDIV: case DREM: it = pop(); it2 = pop(); pushByDoubleMath(seen, it, it2); break; case I2B: it = pop(); if (it.getConstant() != null) { push(new Item("I", new Integer((int)((byte)((Integer)it.getConstant()).intValue())))); } else { push(new Item("I")); } break; case I2C: it = pop(); if (it.getConstant() != null) { push(new Item("I", new Integer((int)((char)((Integer)it.getConstant()).intValue())))); } else { push(new Item("I")); } break; case I2D: it = pop(); if (it.getConstant() != null) { push(new Item("D", new Double((double)((Integer)it.getConstant()).intValue()))); } else { push(new Item("D")); } break; case I2F: it = pop(); if (it.getConstant() != null) { push(new Item("F", new Float((float)((Integer)it.getConstant()).intValue()))); } else { push(new Item("F")); } break; case I2L: it = pop(); if (it.getConstant() != null) { push(new Item("J", new Long((long)((Integer)it.getConstant()).intValue()))); } else { push(new Item("J")); } break; case I2S: it = pop(); if (it.getConstant() != null) { push(new Item("I", new Integer((int)((short)((Integer)it.getConstant()).intValue())))); } else { push(new Item("I")); } break; case D2I: it = pop(); if (it.getConstant() != null) { push(new Item("I", new Integer((int)((Integer)it.getConstant()).intValue()))); } else { push(new Item("I")); } break; case D2F: it = pop(); if (it.getConstant() != null) { push(new Item("F", new Float((float)((Double)it.getConstant()).doubleValue()))); } else { push(new Item("F")); } break; case D2L: it = pop(); if (it.getConstant() != null) { push(new Item("J", new Long((long)((Double)it.getConstant()).doubleValue()))); } else { push(new Item("J")); } break; case L2I: it = pop(); if (it.getConstant() != null) { push(new Item("I", new Integer((int)((Long)it.getConstant()).longValue()))); } else { push(new Item("I")); } break; case L2D: it = pop(); if (it.getConstant() != null) { push(new Item("D", new Double((double)((Long)it.getConstant()).longValue()))); } else { push(new Item("D")); } break; case L2F: it = pop(); if (it.getConstant() != null) { push(new Item("F", new Float((float)((Long)it.getConstant()).longValue()))); } else { push(new Item("F")); } break; case F2I: it = pop(); if (it.getConstant() != null) { push(new Item("I", new Integer((int)((Float)it.getConstant()).floatValue()))); } else { push(new Item("I")); } break; case F2D: it = pop(); if (it.getConstant() != null) { push(new Item("D", new Double((double)((Float)it.getConstant()).floatValue()))); } else { push(new Item("D")); } break; case NEW: pushBySignature(dbc.getClassConstantOperand()); break; case NEWARRAY: pop(); signature = BasicType.getType((byte)dbc.getIntConstant()).getSignature(); pushBySignature(signature); break; case ANEWARRAY: pop(); pushBySignature("L"+dbc.getClassConstantOperand()+";"); break; case MULTIANEWARRAY: int dims = dbc.getIntConstant(); while ((dims--) > 0) { pop(); } push(new Item(dbc.getClassConstantOperand())); break; case AALOAD: pop(); it = pop(); pushBySignature(it.getElementSignature()); break; case JSR: push(new Item("")); //? break; case INVOKEINTERFACE: case INVOKESPECIAL: case INVOKESTATIC: case INVOKEVIRTUAL: pushByInvoke(dbc, seen != INVOKESTATIC); break; default: throw new UnsupportedOperationException("OpCode not supported yet" ); } } catch (Exception e) { //If an error occurs, we clear the stack. one of two things will occur. Either the client will expect more stack //items than really exist, and so they're condition check will fail, or the stack will resync with the code. //But hopefully not false positives stack.clear(); } finally { if (DEBUG) System.out.println(OPCODE_NAMES[seen] + " stack depth: " + getStackDepth()); } } | 7352 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7352/40901f85f52513796517b58176cbcd3534b691e5/OpcodeStack.java/clean/findbugs/src/java/edu/umd/cs/findbugs/OpcodeStack.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
202,
482,
918,
19821,
22808,
12,
1669,
81,
970,
298,
858,
16651,
9881,
16,
509,
5881,
13,
288,
3196,
202,
474,
1744,
31,
3196,
202,
5852,
797,
2028,
31,
3196,
202,
780,
3372,
31,
3196,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
202,
482,
918,
19821,
22808,
12,
1669,
81,
970,
298,
858,
16651,
9881,
16,
509,
5881,
13,
288,
3196,
202,
474,
1744,
31,
3196,
202,
5852,
797,
2028,
31,
3196,
202,
780,
3372,
31,
3196,
... |
System.out.println ("got card"); | logger.info ("got card"); | public Vector query (String aSearchString) { Vector retVecVec = new Vector(); //return vector of vectors. // try { //open a connection to the LDAP server System.out.println ("Opening server " + mReadableName); ICardSource Four11AddressBook = getCardSource(); //create the query ITerm query = new TermEqual (new AC_Attribute ("sn", aSearchString)); String[] attributes = {"givenName", "sn", "cn", "o", "mail", "telephoneNumber", "city"}; //query the LDAP server. System.out.println ("Send query" + query); ICardSet cardSet = Four11AddressBook.getCardSet (query, attributes); //Sort the list. String[] sortOrder = {"sn", "cn"}; cardSet.sort (sortOrder); //hack. I've put the for loop in a try block to catch the exception //thrown when cardEnum.hasMoreElements() incorrectly returns true. try { //enumerate thru the cards. for (Enumeration cardEnum = cardSet.getEnumeration(); cardEnum.hasMoreElements(); ) { System.out.println ("got card"); //get the addres card ICard card = (ICard) cardEnum.nextElement(); //get the attributes for this card IAttributeSet attrSet = card.getAttributeSet (); //create a simple vector to hold the attributes values for this card. Vector thisRow = new Vector(6); String commonName = ""; String organization = ""; String mail = ""; String phone = ""; String city = ""; String nickName = ""; // enumerate thru the card attributes. for (Enumeration attEnum = attrSet.getEnumeration(); attEnum.hasMoreElements(); ) { IAttribute attr = (IAttribute) attEnum.nextElement(); String attrName = attr.getName(); if (attrName.equals ("cn")) { commonName = attr.getValue(); } else if (attrName.equals ("o")) { organization = attr.getValue(); } else if (attrName.equals ("mail")) { mail = attr.getValue(); } else if (attrName.equals ("telephoneNumber")) { phone = attr.getValue(); } else if (attrName.equals ("city")) { city = attr.getValue(); } } //create this row for the table. thisRow.addElement (commonName); thisRow.addElement (mail); thisRow.addElement (organization); thisRow.addElement (phone); thisRow.addElement (city); thisRow.addElement (nickName); //add this row to the table retVecVec.addElement (thisRow); } } catch (Exception e) { } // } // catch( LDAPException e ) { // System.out.println( "Error: " + e.toString() ); // } System.out.println ("Done."); return retVecVec; } | 12904 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12904/23223271c91f0c5c3960447f887d1bdf068d137a/AddressBook.java/clean/grendel/sources/grendel/addressbook/AddressBook.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
5589,
282,
843,
261,
780,
279,
2979,
780,
13,
288,
4202,
5589,
325,
12991,
12991,
273,
394,
5589,
5621,
282,
368,
2463,
3806,
434,
10046,
18,
4202,
368,
2868,
775,
288,
4202,
368,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
5589,
282,
843,
261,
780,
279,
2979,
780,
13,
288,
4202,
5589,
325,
12991,
12991,
273,
394,
5589,
5621,
282,
368,
2463,
3806,
434,
10046,
18,
4202,
368,
2868,
775,
288,
4202,
368,
... |
addInterestingFile(data.file); | ResultFile resultFile = new ResultFile(ResultFile.FILE_TYPE_GENERAL, data.file, getTransMeta().getName(), toString()); addResultFile(resultFile); | private boolean openNextFile() { try { lineNumberInFile = 0; debug = "openNextFile : close last file"; if (!closeLastFile()) return false; if (data.files.nrOfFiles() == 0) return false; // Is this the last file? data.isLastFile = (data.filenr == data.files.nrOfFiles() - 1); data.file = data.files.getFile(data.filenr); data.filename = data.file.getPath(); addInterestingFile(data.file); debug = "openNextFile : open file"; logBasic("Opening file: " + data.filename); data.fr = new FileInputStream(data.file); data.dataErrorLineHandler.handleFile(data.file); if (meta.isZipped()) { data.zi = new ZipInputStream(data.fr); data.zi.getNextEntry(); if (meta.getEncoding() != null && meta.getEncoding().length() > 0) { data.isr = new InputStreamReader(new BufferedInputStream(data.zi), meta.getEncoding()); } else { data.isr = new InputStreamReader(new BufferedInputStream(data.zi)); } } else { if (meta.getEncoding() != null && meta.getEncoding().length() > 0) { data.isr = new InputStreamReader(new BufferedInputStream(data.fr), meta.getEncoding()); } else { data.isr = new InputStreamReader(new BufferedInputStream(data.fr)); } } debug = "openNextFile : set all kinds of parameters"; // Move file pointer ahead! data.filenr++; // ///////////////////////////////////////////////////////////////////////////// // Read the first lines... /* Keep track of the status of the file: are there any lines left to read? */ data.doneReading = false; /* OK, read a number of lines in the buffer: The header rows The nr rows in the page : optional The footer rows */ int bufferSize = 1; // try to read at least one line. bufferSize += meta.hasHeader() ? meta.getNrHeaderLines() : 0; bufferSize += meta.isLayoutPaged() ? meta.getNrLinesPerPage() : 0; bufferSize += meta.hasFooter() ? meta.getNrFooterLines() : 0; // See if we need to skip the document header lines... if (meta.isLayoutPaged()) { for (int i = 0; i < meta.getNrLinesDocHeader(); i++) { // Just skip these... getLine(log, data.isr, meta.getFileFormat()); // header and footer: not wrapped lineNumberInFile++; } } String line; for (int i = 0; i < bufferSize && !data.doneReading; i++) { line = getLine(log, data.isr, meta.getFileFormat()); if (line != null) { // logRowlevel("LINE READ: "+line); linesInput++; lineNumberInFile++; // when there is no header, check the filter for the first line if (!meta.hasHeader()) { // Filter row? boolean isFilterLastLine = false; boolean filterOK = checkFilterRow(line, isFilterLastLine); if (filterOK) { data.lineBuffer.add(new TextFileLine(line, lineNumberInFile, data.file)); // Store it in the // line buffer... } else { if (isFilterLastLine) { data.doneReading = true; } bufferSize++; // grab another line, this one got filtered } } else //there is a header, so don�t checkFilterRow { data.lineBuffer.add(new TextFileLine(line, lineNumberInFile, data.file)); // Store it in the // line buffer... } } else { data.doneReading = true; } } // Reset counters etc. data.headerLinesRead = 0; data.footerLinesRead = 0; data.pageLinesRead = 0; // Set a flags data.doneWithHeader = !meta.hasHeader(); } catch (Exception e) { logError("Couldn't open file #" + data.filenr + " : " + data.filename + " (" + debug + ") --> " + e.toString()); stopAll(); setErrors(1); return false; } return true; } | 9547 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9547/dec476e31491451da3a8cd348e87c60e7e36c715/TextFileInput.java/clean/src/be/ibridge/kettle/trans/step/textfileinput/TextFileInput.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
1250,
1696,
2134,
812,
1435,
202,
95,
202,
202,
698,
202,
202,
95,
1082,
202,
1369,
1854,
382,
812,
273,
374,
31,
1082,
202,
4148,
273,
315,
3190,
2134,
812,
294,
1746,
1142,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1696,
2134,
812,
1435,
202,
95,
202,
202,
698,
202,
202,
95,
1082,
202,
1369,
1854,
382,
812,
273,
374,
31,
1082,
202,
4148,
273,
315,
3190,
2134,
812,
294,
1746,
1142,... |
dlog.println("#if <FALSE> " + new String(buffer,start+1,len-1)); | if (dlog != null) dlog.println("#if <FALSE> " + new String(buffer,start+1,len-1)); | private void handlePPDirective() throws ScannerException { char[] buffer = bufferStack[bufferStackPos]; int limit = bufferLimit[bufferStackPos]; skipOverWhiteSpace(); // find the directive int start = ++bufferPos[bufferStackPos]; // if new line or end of buffer, we're done if (start >= limit || buffer[start] == '\n') return; char c = buffer[start]; if ((c >= 'a' && c <= 'z')) { while (++bufferPos[bufferStackPos] < limit) { c = buffer[bufferPos[bufferStackPos]]; if ((c >= 'a' && c <= 'z') || c == '_') continue; else break; } --bufferPos[bufferStackPos]; int len = bufferPos[bufferStackPos] - start + 1; int type = ppKeywords.get(buffer, start, len); if (type != ppKeywords.undefined) { switch (type) { case ppInclude: handlePPInclude(false); return; case ppInclude_next: handlePPInclude(true); return; case ppDefine: handlePPDefine(); return; case ppUndef: handlePPUndef(); return; case ppIfdef: handlePPIfdef(true); return; case ppIfndef: handlePPIfdef(false); return; case ppIf: start = bufferPos[bufferStackPos]; skipToNewLine(); len = bufferPos[bufferStackPos] - start; if (expressionEvaluator.evaluate(buffer, start, len, definitions) == 0) { dlog.println("#if <FALSE> " + new String(buffer,start+1,len-1)); skipOverConditionalCode(true); } else dlog.println("#if <TRUE> " + new String(buffer,start+1,len-1)); return; case ppElse: case ppElif: // Condition must have been true, skip over the rest skipToNewLine(); skipOverConditionalCode(false); return; case ppError: throw new ScannerException(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/ded9a06c420f7351bdda07dd557f112740190ecb/Scanner2.java/clean/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/parser/scanner2/Scanner2.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1640,
6584,
13307,
1435,
1216,
19074,
503,
288,
202,
202,
3001,
8526,
1613,
273,
1613,
2624,
63,
4106,
2624,
1616,
15533,
202,
202,
474,
1800,
273,
1613,
3039,
63,
4106,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1640,
6584,
13307,
1435,
1216,
19074,
503,
288,
202,
202,
3001,
8526,
1613,
273,
1613,
2624,
63,
4106,
2624,
1616,
15533,
202,
202,
474,
1800,
273,
1613,
3039,
63,
4106,
2... |
this.attributes = attributes; | this.attributes = new AttributesImpl(attributes); | StartEvent(Pattern pattern, String namespaceURI, String localName, String qName, Attributes attributes, Locator locator) { super(namespaceURI, localName, qName, locator); // locator impl is used to take a snapshot! this.attributes = attributes; this.pattern = pattern; } | 51060 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51060/7177ff8f31734f293185997e0a81156f64bc26a6/StartEvent.java/buggy/logback-core/src/main/java/ch/qos/logback/core/joran/spi/StartEvent.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3603,
1133,
12,
3234,
1936,
16,
514,
19421,
16,
514,
11927,
16,
514,
22914,
16,
1377,
9055,
1677,
16,
2851,
639,
8871,
13,
288,
565,
2240,
12,
4937,
3098,
16,
11927,
16,
22914,
16,
8871... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3603,
1133,
12,
3234,
1936,
16,
514,
19421,
16,
514,
11927,
16,
514,
22914,
16,
1377,
9055,
1677,
16,
2851,
639,
8871,
13,
288,
565,
2240,
12,
4937,
3098,
16,
11927,
16,
22914,
16,
8871... |
public static void main(String[] args) { org.objectweb.proactive.examples.nbody.common.Start.main(args) ; | public static void main(String[] args) { org.objectweb.proactive.examples.nbody.common.Start.main(args); | public static void main(String[] args) { org.objectweb.proactive.examples.nbody.common.Start.main(args) ; } | 14315 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/14315/6a4103af87bfad7bfca1448432f5e4b1f5196ffe/Start.java/clean/src/org/objectweb/proactive/examples/nbody/groupoospmd/Start.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
288,
1850,
2358,
18,
1612,
4875,
18,
685,
3535,
18,
16858,
18,
82,
3432,
18,
6054,
18,
1685,
18,
5254,
12,
1968,
13,
274,
377,
289,
2,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
288,
1850,
2358,
18,
1612,
4875,
18,
685,
3535,
18,
16858,
18,
82,
3432,
18,
6054,
18,
1685,
18,
5254,
12,
1968,
13,
274,
377,
289,
2,
... |
_notifyObject(_notifierLock); | _notifyLock(); | public void debuggerStarted() { // EventHandler's thread: test should wait synchronized(_notifierLock) { debuggerStartedCount++; if (printEvents) System.out.println("debuggerStarted " + debuggerStartedCount); _notifyObject(_notifierLock); } } | 11192 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11192/da5a0dd68bcb282274a520304e64e7f255ef6c4e/DebugTest.java/clean/drjava/src/edu/rice/cs/drjava/model/debug/DebugTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
19977,
9217,
1435,
288,
1377,
368,
26012,
1807,
2650,
30,
1842,
1410,
2529,
1377,
3852,
24899,
902,
1251,
2531,
13,
288,
3639,
19977,
9217,
1380,
9904,
31,
3639,
309,
261,
1188,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
19977,
9217,
1435,
288,
1377,
368,
26012,
1807,
2650,
30,
1842,
1410,
2529,
1377,
3852,
24899,
902,
1251,
2531,
13,
288,
3639,
19977,
9217,
1380,
9904,
31,
3639,
309,
261,
1188,
... |
Namespace n = (Namespace) e; nm = name.substring(idx + 2); return lookup(n, nm); } Iterator i = ns.getOwnedElement().iterator(); while (i.hasNext()) { ModelElement e = (ModelElement) i.next(); if (name.equals(e.getName())) { return e; | Iterator i = ns.getOwnedElement().iterator(); while (i.hasNext()) { ModelElement e = (ModelElement) i.next(); if (name.equals(e.getName())) { return e; } | private ModelElement lookup(Namespace ns, String name) { int idx = name.indexOf("::"); if (idx != -1) { String nm; nm = name.substring(0, idx); ModelElement e = lookup(ns, nm); if (e == null || !(e instanceof Namespace)) { return null; } Namespace n = (Namespace) e; nm = name.substring(idx + 2); return lookup(n, nm); } Iterator i = ns.getOwnedElement().iterator(); while (i.hasNext()) { ModelElement e = (ModelElement) i.next(); if (name.equals(e.getName())) { return e; } } return null; } | 7166 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7166/7bc74175450c014e7dde397ce290d1c53120b35f/FacadeMDRImpl.java/buggy/src/model-mdr/src/org/argouml/model/mdr/FacadeMDRImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
3164,
1046,
3689,
12,
3402,
3153,
16,
514,
508,
13,
288,
3639,
509,
2067,
273,
508,
18,
31806,
2932,
30,
2773,
1769,
3639,
309,
261,
3465,
480,
300,
21,
13,
288,
5411,
514,
8442,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3164,
1046,
3689,
12,
3402,
3153,
16,
514,
508,
13,
288,
3639,
509,
2067,
273,
508,
18,
31806,
2932,
30,
2773,
1769,
3639,
309,
261,
3465,
480,
300,
21,
13,
288,
5411,
514,
8442,
... |
XJUtils.deleteDirectory(outputFileDir); | protected boolean prepare() { try { setOutputPath(AWPrefs.getOutputPath()); setStartRule(AWPrefs.getStartSymbol()); fileParser = codeGenerator.getGeneratedTextFileName(false); fileLexer = codeGenerator.getGeneratedTextFileName(true); fileRemoteParser = XJUtils.concatPath(codeGenerator.getOutputPath(), remoteParserClassName+".java"); fileRemoteParserInputText = XJUtils.concatPath(codeGenerator.getOutputPath(), remoteParserClassName+"_input.txt"); outputFileDir = XJUtils.concatPath(codeGenerator.getOutputPath(), "classes"); XJUtils.deleteDirectory(outputFileDir); new File(outputFileDir).mkdirs(); } catch(Exception e) { debugger.getConsole().print(e); String msg = ErrorListener.shared().getFirstErrorMessage(); StringBuffer sb = new StringBuffer("Error while preparing the grammar:\n"); if(msg != null) { sb.append(msg); sb.append("\n"); } sb.append(e.toString()); reportError(sb.toString()); return false; } return true; } | 51505 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51505/2f30fd3ffa62465ed1ebff0b0e43b984ea76a192/DBLocal.java/buggy/src/org/antlr/works/debugger/local/DBLocal.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
1250,
2911,
1435,
288,
3639,
775,
288,
5411,
18113,
743,
12,
12999,
1386,
2556,
18,
588,
1447,
743,
10663,
5411,
18171,
2175,
12,
12999,
1386,
2556,
18,
588,
1685,
5335,
10663,
5411,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
1250,
2911,
1435,
288,
3639,
775,
288,
5411,
18113,
743,
12,
12999,
1386,
2556,
18,
588,
1447,
743,
10663,
5411,
18171,
2175,
12,
12999,
1386,
2556,
18,
588,
1685,
5335,
10663,
5411,
... | |
LOG.assertTrue(startOffset >= 0, "Invalid value: "+startOffset); LOG.assertTrue(endOffset >= 0, "Invalid value: "+endOffset); | if (startOffset < 0) { LOG.error("Invalid startOffset:" + startOffset); } if (endOffset < 0) { LOG.error("Invalid endOffset:" + endOffset); } | protected void setElementAt(int i, int startOffset, int endOffset) { LOG.assertTrue(startOffset >= 0, "Invalid value: "+startOffset); LOG.assertTrue(endOffset >= 0, "Invalid value: "+endOffset); if(i >= mySegmentCount) { mySegmentCount = i+1; } myStarts = relocateArray(myStarts, i); myStarts[i] = startOffset; myEnds = relocateArray(myEnds, i); myEnds[i] = endOffset; } | 12814 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12814/dfb11624e4c6d9894ddcf4341fb7400aad29cbe3/SegmentArray.java/clean/source/com/intellij/openapi/editor/ex/util/SegmentArray.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
918,
26692,
861,
12,
474,
277,
16,
509,
18245,
16,
509,
25507,
13,
288,
565,
2018,
18,
11231,
5510,
12,
1937,
2335,
1545,
374,
16,
315,
1941,
460,
30,
13773,
1937,
2335,
1769,
565... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
26692,
861,
12,
474,
277,
16,
509,
18245,
16,
509,
25507,
13,
288,
565,
2018,
18,
11231,
5510,
12,
1937,
2335,
1545,
374,
16,
315,
1941,
460,
30,
13773,
1937,
2335,
1769,
565... |
assertFalse("expected <" + constraint + "> to return false when passed <" + argument + ">", constraint.eval(argument)); } | assertFalse("expected <" + constraint + "> to return false when passed <" + argument + ">", constraint.eval(argument)); } | private void assertConstraintFalse( Constraint constraint, Object argument ) { assertFalse("expected <" + constraint + "> to return false when passed <" + argument + ">", constraint.eval(argument)); } | 54028 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54028/c26c57f3ac4851e6bc9c5df8515ac73f4045eebf/MockObjectSupportTestCaseTest.java/buggy/jmock/core/src/test/jmock/core/MockObjectSupportTestCaseTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1815,
5806,
8381,
12,
10770,
4954,
16,
1033,
1237,
262,
288,
202,
202,
11231,
8381,
2932,
3825,
411,
6,
397,
4954,
397,
14402,
358,
327,
629,
1347,
2275,
411,
6,
397,
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,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1815,
5806,
8381,
12,
10770,
4954,
16,
1033,
1237,
262,
288,
202,
202,
11231,
8381,
2932,
3825,
411,
6,
397,
4954,
397,
14402,
358,
327,
629,
1347,
2275,
411,
6,
397,
12... |
if ((type & EventSchedule.RELEVANT) != 0) { final InstanceData updatedInstanceData = XFormsUtils.getInstanceDataUpdateInherited(currentNodeInfo); final boolean currentRelevantState = updatedInstanceData.getInheritedRelevant().get(); if (currentRelevantState) { containingDocument.dispatchEvent(pipelineContext, new XFormsEnabledEvent(controlInfo)); } else { containingDocument.dispatchEvent(pipelineContext, new XFormsDisabledEvent(controlInfo)); } | { final boolean previousRelevantState = updatedInstanceData.getPreviousInheritedRelevantState(); final boolean newRelevantState = updatedInstanceData.getInheritedRelevant().get(); if ((previousRelevantState && !newRelevantState) || (!previousRelevantState && newRelevantState)) eventsToDispatch.add(new EventSchedule(controlInfo.getId(), currentNode, EventSchedule.RELEVANT)); | public void doRefresh(final PipelineContext pipelineContext) { // "1. All UI bindings should be reevaluated as necessary." // "2. A node can be changed by confirmed user input to a form control, by // xforms-recalculate (section 4.3.6) or by the setvalue (section 10.1.9) action. If the // value of an instance data node was changed, then the node must be marked for // dispatching the xforms-value-changed event." // "3. If the xforms-value-changed event is marked for dispatching, then all of the // appropriate model item property notification events must also be marked for // dispatching (xforms-optional or xforms-required, xforms-readwrite or xforms-readonly, // and xforms-enabled or xforms-disabled)." // "4. For each form control, each notification event that is marked for dispatching on // the bound node must be dispatched (xforms-value-changed, xforms-valid, // xforms-invalid, xforms-optional, xforms-required, xforms-readwrite, xforms-readonly, // and xforms-enabled, xforms-disabled). The notification events xforms-out-of-range or // xforms-in-range must also be dispatched as appropriate. This specification does not // specify an ordering for the events." final XFormsControls xformsControls = containingDocument.getXFormsControls(); if (xformsControls != null) { // Rebuild controls xformsControls.rebuildCurrentControlsState(pipelineContext); // Build list of events to send final List eventsToDispatch = new ArrayList(); // Iterate through controls and check the nodes they are bound to xformsControls.visitAllControlInfo(new XFormsControls.ControlInfoVisitorListener() { public void startVisitControl(ControlInfo controlInfo) { xformsControls.setBinding(pipelineContext, controlInfo); final NodeInfo currentNodeInfo = xformsControls.getCurrentSingleNode(); // This can happen if control is not bound to anything if (currentNodeInfo == null) return; // We only dispatch value-changed events for controls bound to a mutable document if (!(currentNodeInfo instanceof NodeWrapper)) return; final Node currentNode = (Node) ((NodeWrapper) currentNodeInfo).getUnderlyingNode();// NOTE: we don't actually use the node later below final InstanceData updatedInstanceData = XFormsUtils.getInstanceDataUpdateInherited(currentNodeInfo); // Check if value has changed final boolean valueChanged = updatedInstanceData.isValueChanged(); // TODO: should check whether value of control has changed, not node. // However, is this compatible with with the way we rebuild the controls? if (valueChanged) { // Value change takes care of everything eventsToDispatch.add(new EventSchedule(controlInfo.getId(), currentNode, EventSchedule.ALL)); } else { // Dispatch xforms-optional/xforms-required if needed { final boolean previousRequiredState = updatedInstanceData.getPreviousRequiredState(); final boolean newRequiredState = updatedInstanceData.getRequired().get(); if ((previousRequiredState && !newRequiredState) || (!previousRequiredState && newRequiredState)) eventsToDispatch.add(new EventSchedule(controlInfo.getId(), currentNode, EventSchedule.REQUIRED)); } // Dispatch xforms-enabled/xforms-disabled if needed { final boolean previousRelevantState = updatedInstanceData.getPreviousInheritedRelevantState(); final boolean newRelevantState = updatedInstanceData.getInheritedRelevant().get(); if ((previousRelevantState && !newRelevantState) || (!previousRelevantState && newRelevantState)) eventsToDispatch.add(new EventSchedule(controlInfo.getId(), currentNode, EventSchedule.RELEVANT)); } // Dispatch xforms-readonly/xforms-readwrite if needed { final boolean previousReadonlyState = updatedInstanceData.getPreviousInheritedReadonlyState(); final boolean newReadonlyState = updatedInstanceData.getInheritedReadonly().get(); if ((previousReadonlyState && !newReadonlyState) || (!previousReadonlyState && newReadonlyState)) eventsToDispatch.add(new EventSchedule(controlInfo.getId(), currentNode, EventSchedule.READONLY)); } // Dispatch xforms-valid/xforms-invalid if needed // NOTE: There is no mention in the spec that these events should be // displatched automatically when the value has changed, contrary to the // other events above. { final boolean previousValidState = updatedInstanceData.getPreviousValidState(); final boolean newValidState = updatedInstanceData.getValid().get(); if ((previousValidState && !newValidState) || (!previousValidState && newValidState)) eventsToDispatch.add(new EventSchedule(controlInfo.getId(), currentNode, EventSchedule.VALID)); } } } public void endVisitControl(ControlInfo controlInfo) { } }); // Clear InstanceData event state clearInstanceDataEventState(); // Send events and (try to) make sure the event corresponds to the current instance data // NOTE: deferred behavior is broken in XForms 1.0; 1.1 should introduce better // behavior. Also, event order and the exact steps to take are under-specified in 1.0. for (Iterator i = eventsToDispatch.iterator(); i.hasNext();) { final EventSchedule eventSchedule = (XFormsModel.EventSchedule) i.next(); final String controlInfoId = eventSchedule.getControlInfoId(); final ControlInfo controlInfo = (ControlInfo) xformsControls.getObjectById(controlInfoId); if (controlInfo == null) { // In this case, the algorithm in the spec is not clear. Many thing can have happened between the // initial determination of a control bound to a changing node, and now, including many events and // actions. continue; } // Re-obtain node to which control is bound, in case things have shifted xformsControls.setBinding(pipelineContext, controlInfo); final NodeInfo currentNodeInfo = xformsControls.getCurrentSingleNode(); final int type = eventSchedule.getType(); if ((type & EventSchedule.VALUE) != 0) { containingDocument.dispatchEvent(pipelineContext, new XFormsValueChangeEvent(controlInfo)); } if (currentNodeInfo != null && currentNodeInfo instanceof NodeWrapper) {// final Node currentNode = (Node) ((NodeWrapper) currentNodeInfo).getUnderlyingNode(); if ((type & EventSchedule.REQUIRED) != 0) { final InstanceData updatedInstanceData = XFormsUtils.getInstanceDataUpdateInherited(currentNodeInfo); final boolean currentRequiredState = updatedInstanceData.getRequired().get(); if (currentRequiredState) { containingDocument.dispatchEvent(pipelineContext, new XFormsRequiredEvent(controlInfo)); } else { containingDocument.dispatchEvent(pipelineContext, new XFormsOptionalEvent(controlInfo)); } } if ((type & EventSchedule.RELEVANT) != 0) { final InstanceData updatedInstanceData = XFormsUtils.getInstanceDataUpdateInherited(currentNodeInfo); final boolean currentRelevantState = updatedInstanceData.getInheritedRelevant().get(); if (currentRelevantState) { containingDocument.dispatchEvent(pipelineContext, new XFormsEnabledEvent(controlInfo)); } else { containingDocument.dispatchEvent(pipelineContext, new XFormsDisabledEvent(controlInfo)); } } if ((type & EventSchedule.READONLY) != 0) { final InstanceData updatedInstanceData = XFormsUtils.getInstanceDataUpdateInherited(currentNodeInfo); final boolean currentReadonlyState = updatedInstanceData.getInheritedReadonly().get(); if (currentReadonlyState) { containingDocument.dispatchEvent(pipelineContext, new XFormsReadonlyEvent(controlInfo)); } else { containingDocument.dispatchEvent(pipelineContext, new XFormsReadwriteEvent(controlInfo)); } } if ((type & EventSchedule.VALID) != 0) { final InstanceData inheritedInstanceData = XFormsUtils.getInstanceDataUpdateInherited(currentNodeInfo); final boolean currentValidState = inheritedInstanceData.getValid().get(); if (currentValidState) { containingDocument.dispatchEvent(pipelineContext, new XFormsValidEvent(controlInfo)); } else { containingDocument.dispatchEvent(pipelineContext, new XFormsInvalidEvent(controlInfo)); } } } } // "5. The user interface reflects the state of the model, which means that all forms // controls reflect for their corresponding bound instance data:" if (xformsControls != null) { containingDocument.getXFormsControls().refreshForModel(pipelineContext, this); } } } | 10097 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10097/cea433d5bce9b2974177c5566f94b0414f010953/XFormsModel.java/buggy/src/java/org/orbeon/oxf/xforms/XFormsModel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
741,
8323,
12,
6385,
13671,
1042,
5873,
1042,
13,
288,
3639,
368,
315,
21,
18,
4826,
6484,
7394,
1410,
506,
283,
14168,
690,
487,
4573,
1199,
3639,
368,
315,
22,
18,
432,
756... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
741,
8323,
12,
6385,
13671,
1042,
5873,
1042,
13,
288,
3639,
368,
315,
21,
18,
4826,
6484,
7394,
1410,
506,
283,
14168,
690,
487,
4573,
1199,
3639,
368,
315,
22,
18,
432,
756... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.