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 |
|---|---|---|---|---|---|---|
MP3File mp3File = new MP3File(new File(args[0]), MP3File.LOAD_IDV1TAG | MP3File.LOAD_IDV2TAG | MP3File.LOAD_MP3TAG); | MP3File mp3File = new MP3File(new File(args[0]), MP3File.LOAD_IDV1TAG | MP3File.LOAD_IDV2TAG ); | public static void main(final String[] args) throws Exception { ID3v24Frame newFrame = new ID3v24Frame("TPE1"); AbstractTagFrameBody tmpFrameBody = newFrame.getBody(); FrameBodyTPE1 body = (FrameBodyTPE1)tmpFrameBody ; MP3File mp3File = new MP3File(new File(args[0]), MP3File.LOAD_IDV1TAG | MP3File.LOAD_IDV2TAG | MP3File.LOAD_MP3TAG); System.out.println(mp3File.displayStructureAsXML()); } | 40452 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/40452/8e6062659057068b4b85fb7b41c567e179db6f7c/TestAudioTagger.java/clean/src/org/jaudiotagger/test/TestAudioTagger.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
6385,
514,
8526,
833,
13,
1216,
1185,
565,
288,
3639,
1599,
23,
90,
3247,
3219,
394,
3219,
273,
394,
1599,
23,
90,
3247,
3219,
2932,
56,
1423,
21,
8863,
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,
760,
918,
2774,
12,
6385,
514,
8526,
833,
13,
1216,
1185,
565,
288,
3639,
1599,
23,
90,
3247,
3219,
394,
3219,
273,
394,
1599,
23,
90,
3247,
3219,
2932,
56,
1423,
21,
8863,
3639,
... |
if( symbol == null || ( a.isType( TypeInfo.t_type) && aSymbol == null ) ) | if( symbol == null || ( a.isType( TypeInfo.t_type) && aSymbol == null ) || a.isType( TypeInfo.t_undef )) | static private boolean deduceTemplateArgument( Map map, ISymbol pSymbol, TypeInfo a ) throws ParserSymbolTableException{//, Map argumentMap ){ ISymbol symbol; boolean pIsAReferenceType = false; Iterator i = pSymbol.getPtrOperators().iterator(); if( i.hasNext() && ((PtrOp)i.next()).getType() == TypeInfo.PtrOp.t_reference ){ pIsAReferenceType = true; } TypeInfo p = getParameterTypeForDeduction( pSymbol ); a = getArgumentTypeForDeduction( a, pIsAReferenceType ); if( p.isType( TypeInfo.t_type ) ){ symbol = p.getTypeSymbol(); ISymbol aSymbol = a.getTypeSymbol(); if( symbol == null || ( a.isType( TypeInfo.t_type) && aSymbol == null ) ) throw new ParserSymbolTableException( ParserSymbolTableException.r_BadTypeInfo ); if( symbol instanceof IDeferredTemplateInstance || symbol.isTemplateInstance() ){ return deduceFromTemplateTemplateArguments(map, symbol, aSymbol); } else { if( symbol.isType( TypeInfo.t_templateParameter ) ){ if( symbol.getTypeInfo().getTemplateParameterType() == TypeInfo.t_typeName ){ //a = getFlatTypeInfo( a ); List aPtrs = a.getPtrOperators(); List pPtrs = p.getPtrOperators(); if( pPtrs != null && pPtrs.size() > 0){ if( aPtrs == null ){ return false; } Iterator pIter = pPtrs.iterator(); ListIterator aIter = aPtrs.listIterator(); PtrOp pOp = null; PtrOp aOp = null; while( pIter.hasNext() ){ pOp = (PtrOp) pIter.next(); if( !aIter.hasNext() ){ return false; } else { aOp = (PtrOp) aIter.next(); if( pOp.getType() == aOp.getType() ){ if( !pOp.equals( aOp ) ){ return false; } else { aIter.remove(); } } else { return false; } } } } //cvlist T if( p.checkBit( TypeInfo.isConst ) ){ if( !a.checkBit( TypeInfo.isConst ) ) return false; a.setBit( false, TypeInfo.isConst); } if( p.checkBit( TypeInfo.isVolatile ) ){ if( !a.checkBit( TypeInfo.isVolatile ) ) return false; a.setBit( false, TypeInfo.isVolatile); } //T return deduceArgument( map, symbol, a ); } else if ( symbol.getTypeInfo().getTemplateParameterType() == TypeInfo.t_template ){ } else { //non-type parameter if( symbol.getTypeInfo().getTemplateParameterType() == a.getType() ){ return deduceArgument( map, symbol, a ); } else { return false; } } } //T (*) ( ), T ( T::* ) ( T ), & variations else if( symbol.isType( TypeInfo.t_function ) ){ if( !(aSymbol instanceof IParameterizedSymbol)|| !aSymbol.isType( TypeInfo.t_function ) ) { return false; } IParameterizedSymbol pFunction = (IParameterizedSymbol)symbol; IParameterizedSymbol aFunction = (IParameterizedSymbol)aSymbol; if( !deduceTemplateArgument( map, pFunction.getReturnType(), aFunction.getReturnType().getTypeInfo() ) ){ return false; } List pPtrs = p.getPtrOperators(); if( pPtrs.size() != 0 ){ PtrOp op = (PtrOp) pPtrs.iterator().next(); if( op.getType() == PtrOp.t_memberPointer ){ TypeInfo info = new TypeInfo( TypeInfo.t_type, 0, aFunction.getContainingSymbol() ); if( !deduceTemplateArgument( map, op.getMemberOf(), info ) ){ return false; } } } List pParams = pFunction.getParameterList(); List aParams = aFunction.getParameterList(); if( pParams.size() != aParams.size() ){ return false; } else { Iterator pIter = pParams.iterator(); Iterator aIter = aParams.iterator(); while( pIter.hasNext() ){ TypeInfo info = ((ISymbol)aIter.next()).getTypeInfo(); if( !deduceTemplateArgument( map, (ISymbol) pIter.next(), info ) ){ return false; } } } return true; } } } else { if( p.isType( TypeInfo.t_templateParameter ) ){ return deduceArgument( map, pSymbol, a ); } if( p.getType() == a.getType() ){ if( p.getDefault() != null ){ return ( p.getDefault().equals( a.getDefault() ) ); } return true; } } return false; } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/6797f7dd40ee0309c5bf6c87a9cae5126402b91e/TemplateEngine.java/buggy/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/parser/pst/TemplateEngine.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
3845,
3238,
1250,
11140,
3965,
2283,
1379,
12,
1635,
852,
16,
4437,
3284,
293,
5335,
16,
1412,
966,
279,
262,
1216,
6783,
5335,
1388,
503,
95,
759,
16,
1635,
1237,
863,
262,
95,
20... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
3845,
3238,
1250,
11140,
3965,
2283,
1379,
12,
1635,
852,
16,
4437,
3284,
293,
5335,
16,
1412,
966,
279,
262,
1216,
6783,
5335,
1388,
503,
95,
759,
16,
1635,
1237,
863,
262,
95,
20... |
AnimationManager() { URL iconsRoot = Platform.getPlugin(PlatformUI.PLUGIN_ID).find( new Path(ProgressManager.PROGRESS_FOLDER)); ProgressManager manager = ProgressManager.getInstance(); try { URL runningRoot = new URL(iconsRoot, RUNNING_ICON); URL backRoot = new URL(iconsRoot, BACKGROUND_ICON); animatedData = manager.getImageData(runningRoot, runLoader); if (animatedData != null) JFaceResources.getImageRegistry().put( ANIMATED_IMAGE_NAME, manager.getImage(animatedData[0])); disabledData = manager.getImageData(backRoot, runLoader); if (disabledData != null) JFaceResources.getImageRegistry().put( DISABLED_IMAGE_NAME, manager.getImage(disabledData[0])); listener = getProgressListener(); ProgressManager.getInstance().addListener(listener); } catch (MalformedURLException exception) { ProgressManagerUtil.logException(exception); } } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/a23a2f7d8af51ae4aaa0ae21daaa81f092725969/AnimationManager.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/progress/AnimationManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
10816,
1318,
1435,
95,
202,
202,
1785,
14516,
2375,
33,
1082,
202,
8201,
18,
588,
3773,
12,
8201,
5370,
18,
19415,
67,
734,
2934,
4720,
12,
9506,
202,
2704,
743,
12,
5491,
1318,
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,
10816,
1318,
1435,
95,
202,
202,
1785,
14516,
2375,
33,
1082,
202,
8201,
18,
588,
3773,
12,
8201,
5370,
18,
19415,
67,
734,
2934,
4720,
12,
9506,
202,
2704,
743,
12,
5491,
1318,
18... | ||
return getSimpleTypeName(); | String prefix= getPrefix(document, completionOffset); String completion; if (prefix.indexOf('.') != -1) completion= getQualifiedTypeName(); else completion= getSimpleTypeName(); if (isCamelCaseMatching()) return getCamelCaseCompound(prefix, completion); return completion; | public CharSequence getPrefixCompletionText(IDocument document, int completionOffset) { return getSimpleTypeName(); } | 9698 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9698/290489d0b40a893a77b7a81eb233492a84e340b2/LazyJavaTypeCompletionProposal.java/clean/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/LazyJavaTypeCompletionProposal.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
9710,
16182,
11238,
1528,
12,
734,
504,
650,
1668,
16,
509,
8364,
2335,
13,
288,
202,
202,
2463,
8120,
7947,
5621,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
9710,
16182,
11238,
1528,
12,
734,
504,
650,
1668,
16,
509,
8364,
2335,
13,
288,
202,
202,
2463,
8120,
7947,
5621,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
private DataPointComponentType( int value, String name ) | private DataPointComponentType( int value, String name, String literal ) | private DataPointComponentType( int value, String name ) { super( value, name ); } | 12803 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12803/036e8c78765730b146e5854b9d6c397a296fed86/DataPointComponentType.java/buggy/chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/model/attribute/DataPointComponentType.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
1910,
2148,
28116,
12,
509,
460,
16,
514,
508,
262,
202,
95,
202,
202,
9565,
12,
460,
16,
508,
11272,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
1910,
2148,
28116,
12,
509,
460,
16,
514,
508,
262,
202,
95,
202,
202,
9565,
12,
460,
16,
508,
11272,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
" LEFT JOIN pg_description d ON (c.oid=d.objoid) "+ | " LEFT JOIN pg_description d ON (c.oid=d.objoid AND d.objsubid = 0) "+ | public java.sql.ResultSet getTables(String catalog, String schemaPattern, String tableNamePattern, String types[]) throws SQLException { String select; String orderby; String useSchemas; if (connection.haveMinimumServerVersion("7.3")) { useSchemas = "SCHEMAS"; select = "SELECT NULL AS TABLE_CAT, n.nspname AS TABLE_SCHEM, c.relname AS TABLE_NAME, "+ " CASE n.nspname LIKE 'pg\\\\_%' "+ " WHEN true THEN CASE n.nspname "+ " WHEN 'pg_catalog' THEN CASE c.relkind "+ " WHEN 'r' THEN 'SYSTEM TABLE' "+ " WHEN 'v' THEN 'SYSTEM VIEW' "+ " WHEN 'i' THEN 'SYSTEM INDEX' "+ " ELSE NULL "+ " END "+ " WHEN 'pg_toast' THEN CASE c.relkind "+ " WHEN 'r' THEN 'SYSTEM TOAST TABLE' "+ " WHEN 'i' THEN 'SYSTEM TOAST INDEX' "+ " ELSE NULL "+ " END "+ " ELSE CASE c.relkind "+ " WHEN 'r' THEN 'TEMPORARY TABLE' "+ " WHEN 'i' THEN 'TEMPORARY INDEX' "+ " ELSE NULL "+ " END "+ " END "+ " WHEN false THEN CASE c.relkind "+ " WHEN 'r' THEN 'TABLE' "+ " WHEN 'i' THEN 'INDEX' "+ " WHEN 'S' THEN 'SEQUENCE' "+ " WHEN 'v' THEN 'VIEW' "+ " ELSE NULL "+ " END "+ " ELSE NULL "+ " END "+ " AS TABLE_TYPE, d.description AS REMARKS "+ " FROM pg_catalog.pg_namespace n, pg_catalog.pg_class c "+ " LEFT JOIN pg_catalog.pg_description d ON (c.oid = d.objoid) "+ " LEFT JOIN pg_catalog.pg_class dc ON (d.classoid=dc.oid AND dc.relname='pg_class') "+ " LEFT JOIN pg_catalog.pg_namespace dn ON (dn.oid=dc.relnamespace AND dn.nspname='pg_catalog') "+ " WHERE c.relnamespace = n.oid "; if (schemaPattern != null && !"".equals(schemaPattern)) { select += " AND n.nspname LIKE '"+escapeQuotes(schemaPattern)+"' "; } if (tableNamePattern != null) { select += " AND c.relname LIKE '"+escapeQuotes(tableNamePattern)+"' "; } orderby = " ORDER BY TABLE_TYPE,TABLE_SCHEM,TABLE_NAME "; } else { useSchemas = "NOSCHEMAS"; String tableType = ""+ " CASE c.relname LIKE 'pg\\\\_%' "+ " WHEN true THEN CASE c.relname LIKE 'pg\\\\_toast\\\\_%' "+ " WHEN true THEN CASE c.relkind "+ " WHEN 'r' THEN 'SYSTEM TOAST TABLE' "+ " WHEN 'i' THEN 'SYSTEM TOAST INDEX' "+ " ELSE NULL "+ " END "+ " WHEN false THEN CASE c.relname LIKE 'pg\\\\_temp\\\\_%' "+ " WHEN true THEN CASE c.relkind "+ " WHEN 'r' THEN 'TEMPORARY TABLE' "+ " WHEN 'i' THEN 'TEMPORARY INDEX' "+ " ELSE NULL "+ " END "+ " WHEN false THEN CASE c.relkind "+ " WHEN 'r' THEN 'SYSTEM TABLE' "+ " WHEN 'v' THEN 'SYSTEM VIEW' "+ " WHEN 'i' THEN 'SYSTEM INDEX' "+ " ELSE NULL "+ " END "+ " ELSE NULL "+ " END "+ " ELSE NULL "+ " END "+ " WHEN false THEN CASE c.relkind "+ " WHEN 'r' THEN 'TABLE' "+ " WHEN 'i' THEN 'INDEX' "+ " WHEN 'S' THEN 'SEQUENCE' "+ " WHEN 'v' THEN 'VIEW' "+ " ELSE NULL "+ " END "+ " ELSE NULL "+ " END "; orderby = " ORDER BY TABLE_TYPE,TABLE_NAME "; if (connection.haveMinimumServerVersion("7.1")) { select = "SELECT NULL AS TABLE_CAT, NULL AS TABLE_SCHEM, c.relname AS TABLE_NAME, "+tableType+" AS TABLE_TYPE, d.description AS REMARKS "+ " FROM pg_class c "+ " LEFT JOIN pg_description d ON (c.oid=d.objoid) "+ " LEFT JOIN pg_class dc ON (d.classoid = dc.oid AND dc.relname='pg_class') "+ " WHERE true "; } else { select = "SELECT NULL AS TABLE_CAT, NULL AS TABLE_SCHEM, c.relname AS TABLE_NAME, "+tableType+" AS TABLE_TYPE, NULL AS REMARKS "+ " FROM pg_class c "+ " WHERE true "; } } if (types == null) { types = defaultTableTypes; } String sql = select; sql += " AND (false "; for (int i=0; i<types.length; i++) { Hashtable clauses = (Hashtable)tableTypeClauses.get(types[i]); if (clauses != null) { String clause = (String)clauses.get(useSchemas); sql += " OR ( "+clause+" ) "; } } sql += ") "; sql += orderby; return connection.createStatement().executeQuery(sql); } | 46597 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46597/5ec61f4d2b129d6630d1c72058b3d381cbf21cbc/AbstractJdbc1DatabaseMetaData.java/clean/src/interfaces/jdbc/org/postgresql/jdbc1/AbstractJdbc1DatabaseMetaData.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
2252,
18,
4669,
18,
13198,
29002,
12,
780,
6222,
16,
514,
1963,
3234,
16,
514,
4775,
3234,
16,
514,
1953,
63,
5717,
1216,
6483,
202,
95,
202,
202,
780,
2027,
31,
202,
202,
7... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
2252,
18,
4669,
18,
13198,
29002,
12,
780,
6222,
16,
514,
1963,
3234,
16,
514,
4775,
3234,
16,
514,
1953,
63,
5717,
1216,
6483,
202,
95,
202,
202,
780,
2027,
31,
202,
202,
7... |
public void breakpointSet(final Breakpoint bp) { DefaultMutableTreeNode bpDocNode = new DefaultMutableTreeNode(bp.getClassName()); Enumeration documents = _breakpointRootNode.children(); while (documents.hasMoreElements()) { DefaultMutableTreeNode doc = (DefaultMutableTreeNode)documents.nextElement(); if (doc.getUserObject().equals(bpDocNode.getUserObject())) { Enumeration lineNumbers = doc.children(); while (lineNumbers.hasMoreElements()) { DefaultMutableTreeNode lineNumber = (DefaultMutableTreeNode)lineNumbers.nextElement(); if (((Integer)lineNumber.getUserObject()).intValue() > bp.getLineNumber()) { DefaultMutableTreeNode newBreakpoint = new DefaultMutableTreeNode(new Integer(bp.getLineNumber())); _bpTreeModel.insertNodeInto(newBreakpoint, doc, doc.getIndex(lineNumber)); _bpTree.scrollPathToVisible(new TreePath(newBreakpoint.getPath())); return; } } DefaultMutableTreeNode newBreakpoint = new DefaultMutableTreeNode(new Integer(bp.getLineNumber())); _bpTreeModel.insertNodeInto(newBreakpoint, doc, doc.getChildCount()); _bpTree.scrollPathToVisible(new TreePath(newBreakpoint.getPath())); return; } } _bpTreeModel.insertNodeInto(bpDocNode, _breakpointRootNode, _breakpointRootNode.getChildCount()); DefaultMutableTreeNode newBreakpoint = new DefaultMutableTreeNode(new Integer(bp.getLineNumber())); _bpTreeModel.insertNodeInto(newBreakpoint, bpDocNode, bpDocNode.getChildCount()); TreePath pathToNewBreakpoint = new TreePath(newBreakpoint.getPath()); _bpTree.scrollPathToVisible(pathToNewBreakpoint); } | public void breakpointSet(final Breakpoint bp) { } | public void breakpointSet(final Breakpoint bp) {// // Only change GUI from event-dispatching thread// Runnable doCommand = new Runnable() {// public void run() { DefaultMutableTreeNode bpDocNode = new DefaultMutableTreeNode(bp.getClassName()); // Look for matching document node // Raw type here due to Swing's use of raw types. Enumeration documents = _breakpointRootNode.children(); while (documents.hasMoreElements()) { DefaultMutableTreeNode doc = (DefaultMutableTreeNode)documents.nextElement(); if (doc.getUserObject().equals(bpDocNode.getUserObject())) { // Create a new breakpoint in this node //Sort breakpoints by line number. // Raw type here due to Swing's use of raw types. Enumeration lineNumbers = doc.children(); while (lineNumbers.hasMoreElements()) { DefaultMutableTreeNode lineNumber = (DefaultMutableTreeNode)lineNumbers.nextElement(); //if line number of indexed breakpoint is less than new breakpoint, continue if (((Integer)lineNumber.getUserObject()).intValue() > bp.getLineNumber()) { //else, add to the list DefaultMutableTreeNode newBreakpoint = new DefaultMutableTreeNode(new Integer(bp.getLineNumber())); _bpTreeModel.insertNodeInto(newBreakpoint, doc, doc.getIndex(lineNumber)); // Make sure this node is visible _bpTree.scrollPathToVisible(new TreePath(newBreakpoint.getPath())); return; } } //if none are greater, add at the end DefaultMutableTreeNode newBreakpoint = new DefaultMutableTreeNode(new Integer(bp.getLineNumber())); _bpTreeModel.insertNodeInto(newBreakpoint, doc, doc.getChildCount()); // Make sure this node is visible _bpTree.scrollPathToVisible(new TreePath(newBreakpoint.getPath())); return; } } // No matching document node was found, so create one _bpTreeModel.insertNodeInto(bpDocNode, _breakpointRootNode, _breakpointRootNode.getChildCount()); DefaultMutableTreeNode newBreakpoint = new DefaultMutableTreeNode(new Integer(bp.getLineNumber())); _bpTreeModel.insertNodeInto(newBreakpoint, bpDocNode, bpDocNode.getChildCount()); // Make visible TreePath pathToNewBreakpoint = new TreePath(newBreakpoint.getPath()); _bpTree.scrollPathToVisible(pathToNewBreakpoint);// }// };// Utilities.invokeLater(doCommand); } | 11192 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11192/5425ae0e836a7ee6f00ac774f834187d377d72ad/DebugPanel.java/clean/drjava/src/edu/rice/cs/drjava/ui/DebugPanel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
18820,
694,
12,
6385,
17030,
1153,
9107,
13,
288,
759,
1377,
368,
5098,
2549,
10978,
628,
871,
17,
10739,
310,
2650,
759,
1377,
10254,
741,
2189,
273,
394,
10254,
1435,
288,
75... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
18820,
694,
12,
6385,
17030,
1153,
9107,
13,
288,
759,
1377,
368,
5098,
2549,
10978,
628,
871,
17,
10739,
310,
2650,
759,
1377,
10254,
741,
2189,
273,
394,
10254,
1435,
288,
75... |
int size = COM.GetClipboardFormatName(types[i].cfFormat, buffer, maxSize); | int size = OS.GetClipboardFormatName(types[i].cfFormat, buffer, maxSize); | public String[] getAvailableTypeNames() { checkWidget(); FORMATETC[] types = _getAvailableTypes(); String[] names = new String[types.length]; int maxSize = 128; for (int i = 0; i < types.length; i++){ TCHAR buffer = new TCHAR(0, maxSize); int size = COM.GetClipboardFormatName(types[i].cfFormat, buffer, maxSize); if (size != 0) { names[i] = buffer.toString(0, size); } else { switch (types[i].cfFormat) { case COM.CF_HDROP: names[i] = "CF_HDROP"; break; //$NON-NLS-1$ case COM.CF_TEXT: names[i] = "CF_TEXT"; break; //$NON-NLS-1$ case COM.CF_BITMAP: names[i] = "CF_BITMAP"; break; //$NON-NLS-1$ case COM.CF_METAFILEPICT: names[i] = "CF_METAFILEPICT"; break; //$NON-NLS-1$ case COM.CF_SYLK: names[i] = "CF_SYLK"; break; //$NON-NLS-1$ case COM.CF_DIF: names[i] = "CF_DIF"; break; //$NON-NLS-1$ case COM.CF_TIFF: names[i] = "CF_TIFF"; break; //$NON-NLS-1$ case COM.CF_OEMTEXT: names[i] = "CF_OEMTEXT"; break; //$NON-NLS-1$ case COM.CF_DIB: names[i] = "CF_DIB"; break; //$NON-NLS-1$ case COM.CF_PALETTE: names[i] = "CF_PALETTE"; break; //$NON-NLS-1$ case COM.CF_PENDATA: names[i] = "CF_PENDATA"; break; //$NON-NLS-1$ case COM.CF_RIFF: names[i] = "CF_RIFF"; break; //$NON-NLS-1$ case COM.CF_WAVE: names[i] = "CF_WAVE"; break; //$NON-NLS-1$ case COM.CF_UNICODETEXT: names[i] = "CF_UNICODETEXT"; break; //$NON-NLS-1$ case COM.CF_ENHMETAFILE: names[i] = "CF_ENHMETAFILE"; break; //$NON-NLS-1$ case COM.CF_LOCALE: names[i] = "CF_LOCALE"; break; //$NON-NLS-1$ case COM.CF_MAX: names[i] = "CF_MAX"; break; //$NON-NLS-1$ default: names[i] = "UNKNOWN"; } } } return names;} | 12413 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12413/441ed9e06bf32a499ab28cffbd9de4abcf50c019/Clipboard.java/buggy/bundles/org.eclipse.swt/Eclipse SWT Drag and Drop/win32/org/eclipse/swt/dnd/Clipboard.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
514,
8526,
15796,
559,
1557,
1435,
288,
202,
1893,
4609,
5621,
202,
7254,
1584,
39,
8526,
1953,
273,
389,
588,
5268,
2016,
5621,
202,
780,
8526,
1257,
273,
394,
514,
63,
2352,
18,
2469,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
514,
8526,
15796,
559,
1557,
1435,
288,
202,
1893,
4609,
5621,
202,
7254,
1584,
39,
8526,
1953,
273,
389,
588,
5268,
2016,
5621,
202,
780,
8526,
1257,
273,
394,
514,
63,
2352,
18,
2469,
... |
public boolean isSet(org.quickfix.field.UnderlyingSecurityAltID field) | public boolean isSet(quickfix.field.UnderlyingSecurityAltID field) | public boolean isSet(org.quickfix.field.UnderlyingSecurityAltID field) { return isSetField(field); } | 5926 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5926/fecc27f98261270772ff182a1d4dfd94b5daa73d/MultilegOrderCancelReplaceRequest.java/buggy/src/java/src/quickfix/fix44/MultilegOrderCancelReplaceRequest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1250,
13532,
12,
19525,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
652,
13,
225,
288,
327,
13532,
974,
12,
1518,
1769,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1250,
13532,
12,
19525,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
652,
13,
225,
288,
327,
13532,
974,
12,
1518,
1769,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
throw new CmsException("[" + this.getClass().getName() + "] "+groupname,CmsException.C_NO_GROUP); } | throw new CmsException("[" + this.getClass().getName() + "] "+id,CmsException.C_NO_GROUP); } | public CmsGroup readGroup(String groupname) throws CmsException { CmsGroup group=null; ResultSet res = null; PreparedStatement statement=null; try{ // read the group from the database statement=m_pool.getPreparedStatement(m_cq.C_GROUPS_READGROUP_KEY); statement.setString(1,groupname); res = statement.executeQuery(); // create new Cms group object if(res.next()) { group=new CmsGroup(res.getInt(m_cq.C_GROUPS_GROUP_ID), res.getInt(m_cq.C_GROUPS_PARENT_GROUP_ID), res.getString(m_cq.C_GROUPS_GROUP_NAME), res.getString(m_cq.C_GROUPS_GROUP_DESCRIPTION), res.getInt(m_cq.C_GROUPS_GROUP_FLAGS)); res.close(); } else { throw new CmsException("[" + this.getClass().getName() + "] "+groupname,CmsException.C_NO_GROUP); } } catch (SQLException e){ throw new CmsException("[" + this.getClass().getName() + "] "+e.getMessage(),CmsException.C_SQL_ERROR, e); } finally { if( statement != null) { m_pool.putPreparedStatement(m_cq.C_GROUPS_READGROUP_KEY,statement); } } return group; } | 8585 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8585/142347a2a551d52971f8e5e2e084c9c08fd422d1/CmsDbAccess.java/buggy/src/com/opencms/file/genericSql/CmsDbAccess.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
1071,
2149,
1114,
855,
1114,
12,
780,
25329,
13,
1082,
1216,
11228,
288,
25083,
2149,
1114,
1041,
33,
2011,
31,
1082,
10842,
400,
273,
446,
31,
1082,
16913,
3021,
33,
2011,
31,
565,
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,
3196,
1071,
2149,
1114,
855,
1114,
12,
780,
25329,
13,
1082,
1216,
11228,
288,
25083,
2149,
1114,
1041,
33,
2011,
31,
1082,
10842,
400,
273,
446,
31,
1082,
16913,
3021,
33,
2011,
31,
565,
1082... |
catch (RemoteException e) { e.printStackTrace(); } catch (FinderException e) { e.printStackTrace(); } return menu; | private DropdownMenu getAllRelationTypesMenu(IWContext iwc) { DropdownMenu menu = new DropdownMenu(PARAM_TYPE); try { Collection types = getRelationTypeHome().findAll(); for (Iterator iter = types.iterator(); iter.hasNext();) { GroupRelationType relType = (GroupRelationType) iter.next(); menu.addMenuElement(relType.getType(), iwrb.getLocalizedString(relType.getType(), relType.getType())); } } catch (RemoteException e) { e.printStackTrace(); } catch (FinderException e) { e.printStackTrace(); } return menu; } | 57353 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57353/8f8c27e1dca0fa83749b04c80fbdce73125364d1/UserRelationConnector.java/buggy/src/java/is/idega/idegaweb/member/presentation/UserRelationConnector.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
10895,
2378,
4599,
5514,
3963,
2016,
4599,
12,
45,
59,
1042,
25522,
71,
13,
288,
202,
202,
23947,
4599,
3824,
273,
394,
10895,
2378,
4599,
12,
8388,
67,
2399,
1769,
202,
202,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
10895,
2378,
4599,
5514,
3963,
2016,
4599,
12,
45,
59,
1042,
25522,
71,
13,
288,
202,
202,
23947,
4599,
3824,
273,
394,
10895,
2378,
4599,
12,
8388,
67,
2399,
1769,
202,
202,
... | |
private static boolean recurseAsIfGroup(SchemaParticle baseModel, SchemaParticle derivedModel, Collection errors, XmlObject context) { // recurseAsIfGroup is called if: // base: ALL, derived: ELEMENT // base: CHOICE, derived: ELEMENT // base: SEQUENCE, derived: ELEMENT assert (baseModel.getParticleType() == SchemaParticle.ALL && derivedModel.getParticleType() == SchemaParticle.ELEMENT) || (baseModel.getParticleType() == SchemaParticle.CHOICE && derivedModel.getParticleType() == SchemaParticle.ELEMENT) || (baseModel.getParticleType() == SchemaParticle.SEQUENCE && derivedModel.getParticleType() == SchemaParticle.ELEMENT); // Schema Component Constraint: Particle Derivation OK (Elt:All/Choice/Sequence -- RecurseAsIfGroup) // For an element declaration particle to be a valid restriction of a group particle // (all, choice or sequence) a group particle of the variety corresponding to B's, with {min occurs} and // {max occurs} of 1 and with {particles} consisting of a single particle the same as the element declaration // must be a valid restriction of the group as defined by Particle Derivation OK // (All:All,Sequence:Sequence -- Recurse) (3.9.6), Particle Derivation OK (Choice:Choice -- RecurseLax) // (3.9.6) or Particle Derivation OK (All:All,Sequence:Sequence -- Recurse) (3.9.6), depending on whether // the group is all, choice or sequence // interpretation: make a fake group of the right type, with min occurs and max occurs of 1 SchemaParticleImpl asIfPart = new SchemaParticleImpl(); asIfPart.setParticleType(baseModel.getParticleType()); asIfPart.setMinOccurs(BigInteger.ONE); asIfPart.setMaxOccurs(BigInteger.ONE); asIfPart.setParticleChildren(new SchemaParticle[] { derivedModel }); // the recurse return isParticleValidRestriction(baseModel, asIfPart, errors, context); } | 3520 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3520/2abb5020b672ce690c4e9ee7b7ac4e53b4a084db/StscChecker.java/clean/src/typeimpl/org/apache/xmlbeans/impl/schema/StscChecker.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
1250,
11502,
1463,
2047,
1114,
12,
3078,
1988,
3711,
1026,
1488,
16,
4611,
1988,
3711,
10379,
1488,
16,
2200,
1334,
16,
5714,
921,
819,
13,
288,
3639,
368,
11502,
1463,
2047,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1250,
11502,
1463,
2047,
1114,
12,
3078,
1988,
3711,
1026,
1488,
16,
4611,
1988,
3711,
10379,
1488,
16,
2200,
1334,
16,
5714,
921,
819,
13,
288,
3639,
368,
11502,
1463,
2047,
1... | ||
if(size > 32768 || size < 0) | if((size > 32768) || (size < 0)) | public Bucket decode(BucketFactory bf, int maxLength, boolean dontCompress) throws CHKDecodeException, IOException { // Overall hash already verified, so first job is to decrypt. if(key.cryptoAlgorithm != Key.ALGO_AES_PCFB_256_SHA256) throw new UnsupportedOperationException(); BlockCipher cipher; try { cipher = new Rijndael(256, 256); } catch (UnsupportedCipherException e) { // FIXME - log this properly throw new Error(e); } byte[] cryptoKey = key.cryptoKey; if(cryptoKey.length < Node.SYMMETRIC_KEY_LENGTH) throw new CHKDecodeException("Crypto key too short"); cipher.initialize(key.cryptoKey); PCFBMode pcfb = new PCFBMode(cipher); byte[] hbuf = new byte[headers.length-2]; System.arraycopy(headers, 2, hbuf, 0, headers.length-2); byte[] dbuf = new byte[data.length]; System.arraycopy(data, 0, dbuf, 0, data.length); // Decipher header first - functions as IV pcfb.blockDecipher(hbuf, 0, hbuf.length); pcfb.blockDecipher(dbuf, 0, dbuf.length); // Check: Decryption key == hash of data (not including header) MessageDigest md256; try { md256 = MessageDigest.getInstance("SHA-256"); } catch (NoSuchAlgorithmException e1) { // FIXME: log this properly? throw new Error(e1); } byte[] dkey = md256.digest(dbuf); if(!java.util.Arrays.equals(dkey, key.cryptoKey)) { throw new CHKDecodeException("Check failed: decrypt key == H(data)"); } // Check: IV == hash of decryption key byte[] predIV = md256.digest(dkey); // Extract the IV byte[] iv = new byte[32]; System.arraycopy(hbuf, 0, iv, 0, 32); if(!Arrays.equals(iv, predIV)) throw new CHKDecodeException("Check failed: Decrypted IV == H(decryption key)"); // Checks complete int size = ((hbuf[32] & 0xff) << 8) + (hbuf[33] & 0xff); if(size > 32768 || size < 0) throw new CHKDecodeException("Invalid size: "+size); byte[] output = new byte[size]; // No particular reason to check the padding, is there? System.arraycopy(dbuf, 0, output, 0, size); return Key.decompress(dontCompress ? false : key.isCompressed(), output, bf, Math.min(maxLength, MAX_LENGTH_BEFORE_COMPRESSION), key.compressionAlgorithm, false); } | 8026 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8026/ca136843ae9ecb30cadada58a33a5dc2cf8ad064/ClientCHKBlock.java/buggy/src/freenet/keys/ClientCHKBlock.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
7408,
2495,
12,
4103,
1733,
16222,
16,
509,
13642,
16,
1250,
14046,
16552,
13,
1216,
6469,
47,
6615,
503,
16,
1860,
288,
3639,
368,
10752,
454,
1651,
1818,
13808,
16,
1427,
1122,
17... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
7408,
2495,
12,
4103,
1733,
16222,
16,
509,
13642,
16,
1250,
14046,
16552,
13,
1216,
6469,
47,
6615,
503,
16,
1860,
288,
3639,
368,
10752,
454,
1651,
1818,
13808,
16,
1427,
1122,
17... |
extenalFiles.add(file); | externalFiles.add(file); | public static String validate(List emfResources) { org.eclipse.core.resources.IWorkspace workspace = org.eclipse.core.resources.ResourcesPlugin.getWorkspace(); org.eclipse.core.resources.IWorkspaceRoot workspaceRoot= workspace.getRoot(); List workspaceFiles = new ArrayList(emfResources.size()); List extenalFiles = new ArrayList(emfResources.size()); for (Iterator i = emfResources.iterator(); i.hasNext();) { Resource resource = (Resource)i.next(); URI uri = resource.getURI().trimFragment(); if (uri.isFile()) { File file = new File(uri.toFileString()); if (file.isFile() && !file.canWrite()) { extenalFiles.add(file); } } else if (uri.isPlatformResource()) { String path = uri.toPlatformString(true); org.eclipse.core.resources.IResource workspaceResource = workspaceRoot.findMember(new org.eclipse.core.runtime.Path(path)); if (workspaceResource != null && workspaceResource.getType() == org.eclipse.core.resources.IResource.FILE && workspaceResource.getResourceAttributes().isReadOnly()) { workspaceFiles.add(workspaceResource); } } } StringBuffer readOnlyFiles = new StringBuffer(); if (!workspaceFiles.isEmpty()) { Object context = null; if (org.eclipse.core.runtime.Platform.getBundle("org.eclipse.swt") != null) { context = ShellFinder.getActiveShell(); } org.eclipse.core.resources.IFile[] files = (org.eclipse.core.resources.IFile[])workspaceFiles.toArray(new org.eclipse.core.resources.IFile [workspaceFiles.size()]); if (!workspace.validateEdit(files, context).isOK()) { for (int i = 0; i < files.length; i++) { if (files[i].isReadOnly()) { readOnlyFiles.append(", ").append(files[i].getFullPath().toString()); } } } } if (!extenalFiles.isEmpty()) { for (Iterator i = extenalFiles.iterator(); i.hasNext();) { File file = (File)i.next(); readOnlyFiles.append(", ").append(file.getAbsolutePath()); } } return readOnlyFiles.length() == 0 ? null : readOnlyFiles.deleteCharAt(0).deleteCharAt(0).toString(); } | 11224 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11224/99275521e4f2349657575e0d8128a39e75d5c1d3/ConverterUtil.java/buggy/plugins/org.eclipse.emf.converter/src/org/eclipse/emf/converter/util/ConverterUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
1954,
12,
682,
801,
74,
3805,
13,
565,
288,
1377,
2358,
18,
20416,
18,
3644,
18,
4683,
18,
45,
8241,
6003,
273,
2358,
18,
20416,
18,
3644,
18,
4683,
18,
3805,
3773,
18... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
1954,
12,
682,
801,
74,
3805,
13,
565,
288,
1377,
2358,
18,
20416,
18,
3644,
18,
4683,
18,
45,
8241,
6003,
273,
2358,
18,
20416,
18,
3644,
18,
4683,
18,
3805,
3773,
18... |
public static StringValue repeat(final int times, final String s) | public static StringValue repeat(final int times, final char c) | public static StringValue repeat(final int times, final String s) { final StringBuffer buffer = new StringBuffer(times); for (int i = 0; i < times; i++) { buffer.append(s); } return valueOf(buffer); } | 46434 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46434/0277c874fa39724125f6156aaeb6a6131d536e32/StringValue.java/buggy/wicket/src/java/wicket/util/string/StringValue.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
18595,
7666,
12,
6385,
509,
4124,
16,
727,
514,
272,
13,
202,
95,
202,
202,
6385,
6674,
1613,
273,
394,
6674,
12,
8293,
1769,
202,
202,
1884,
261,
474,
277,
273,
374,
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,
760,
18595,
7666,
12,
6385,
509,
4124,
16,
727,
514,
272,
13,
202,
95,
202,
202,
6385,
6674,
1613,
273,
394,
6674,
12,
8293,
1769,
202,
202,
1884,
261,
474,
277,
273,
374,
3... |
if (initialFileName != null) resourceGroup.setResource(initialFileName); | if (initialFileName != null) { resourceGroup.setResource(initialFileName); } | public void createControl(Composite parent) { initializeDialogUnits(parent); // top level group Composite topLevel = new Composite(parent, SWT.NONE); topLevel.setLayout(new GridLayout()); topLevel.setLayoutData(new GridData(GridData.VERTICAL_ALIGN_FILL | GridData.HORIZONTAL_ALIGN_FILL)); topLevel.setFont(parent.getFont()); PlatformUI.getWorkbench().getHelpSystem().setHelp(topLevel, IIDEHelpContextIds.NEW_FILE_WIZARD_PAGE); // resource and container group resourceGroup = new ResourceAndContainerGroup( topLevel, this, getNewFileLabel(), IDEWorkbenchMessages.WizardNewFileCreationPage_file, false, SIZING_CONTAINER_GROUP_HEIGHT); resourceGroup.setAllowExistingResources(false); initialPopulateContainerNameField(); createAdvancedControls(topLevel); if (initialFileName != null) resourceGroup.setResource(initialFileName); validatePage(); // Show description on opening setErrorMessage(null); setMessage(null); setControl(topLevel); } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/e38d295ea613cf9f08aadb93a84a33d2e91abc5f/WizardNewFileCreationPage.java/clean/bundles/org.eclipse.ui.ide/extensions/org/eclipse/ui/dialogs/WizardNewFileCreationPage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
752,
3367,
12,
9400,
982,
13,
288,
3639,
4046,
6353,
7537,
12,
2938,
1769,
3639,
368,
1760,
1801,
1041,
3639,
14728,
21289,
273,
394,
14728,
12,
2938,
16,
348,
8588,
18,
9826,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
752,
3367,
12,
9400,
982,
13,
288,
3639,
4046,
6353,
7537,
12,
2938,
1769,
3639,
368,
1760,
1801,
1041,
3639,
14728,
21289,
273,
394,
14728,
12,
2938,
16,
348,
8588,
18,
9826,
... |
public boolean read(ByteBuffer buffer) throws MessageParseException { for (;;) { try { if (state == SEEKING_HEADER) { if (buffer.remaining() < headerBytes.length) { break; } // TODO PERFORMANCE this can be optimized in recognizer messageStartPosition = indexOf(buffer, buffer.position(), headerBytes); if (messageStartPosition == -1) { // TODO this is actually an error break; } log.debug("found header"); position = messageStartPosition + headerBytes.length; state = PARSING_LENGTH; } if (state == PARSING_LENGTH) { bodyLength = 0; byte ch = buffer.get(position++); while (Character.isDigit((char) ch)) { bodyLength = bodyLength * 10 + (ch - '0'); if (buffer.hasRemaining()) { ch = buffer.get(position++); } else { break; } } if (ch != '\001') { handleError(buffer, "Error in message length", false); break; } bodyStartPosition = position; state = READING_BODY; log.debug("reading body, length = " + bodyLength); } if (state == READING_BODY) { if ((buffer.limit() - position) < bodyLength) { break; } position += bodyLength; state = PARSING_CHECKSUM; } if (state == PARSING_CHECKSUM) { if (startsWith(buffer, position, checksumBytes)) { log.debug("parsing checksum"); position += checksumBytes.length; } else { handleError(buffer, "did not find checksum field, bad length?", isLogon( buffer, messageStartPosition)); if (buffer.remaining() > 0) { continue; } else { break; } } byte[] data = new byte[position - messageStartPosition]; buffer.position(messageStartPosition); buffer.get(data); message = new String(data); if (log.isTraceEnabled()) { log.trace("extracted message: " + message + ", remaining=" + buffer.remaining()); } return true; } } catch (Throwable t) { state = SEEKING_HEADER; throw new MessageParseException(t); } } return false; } | 6791 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6791/e15268f9536651e3fa9c651353c4faa94eb88b1a/FIXMessageData.java/clean/src/quickfix/netty/FIXMessageData.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
6494,
896,
12,
12242,
4106,
13,
15069,
1079,
13047,
95,
1884,
12,
25708,
15329,
698,
95,
430,
12,
2019,
631,
1090,
11325,
1360,
67,
7557,
15329,
430,
12,
4106,
18,
17956,
1435,
32,
3374,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
6494,
896,
12,
12242,
4106,
13,
15069,
1079,
13047,
95,
1884,
12,
25708,
15329,
698,
95,
430,
12,
2019,
631,
1090,
11325,
1360,
67,
7557,
15329,
430,
12,
4106,
18,
17956,
1435,
32,
3374,... | ||
if(text.equals("More Windows...")) { | if (text.equals("More Windows...")) { | void removeWindow(FileWindow w) { fileWindows.remove(w.getUrl()); JMenu windowMenu = getWindowMenu(); int count = windowMenu.getItemCount(); JMenuItem lastItem = windowMenu.getItem(count -1); String name = new File(w.getUrl()).getName(); for(int i = 5; i < count; i++) { JMenuItem item = windowMenu.getItem(i); if(item == null) continue; // separator String text = item.getText(); //1 D:\foo.js //2 D:\bar.js int pos = text.indexOf(' '); if(text.substring(pos + 1).equals(name)) { windowMenu.remove(item); // Cascade [0] // Tile [1] // ------- [2] // Console [3] // ------- [4] if(count == 6) { // remove the final separator windowMenu.remove(4); } else { int j = i - 4; for(;i < count -1; i++) { JMenuItem thisItem = windowMenu.getItem(i); if(thisItem != null) { //1 D:\foo.js //2 D:\bar.js text = thisItem.getText(); if(text.equals("More Windows...")) { break; } else { pos = text.indexOf(' '); thisItem.setText((char)('0' + j) + " " + text.substring(pos + 1)); thisItem.setMnemonic('0' + j); j++; } } } if(count - 6 == 0 && lastItem != item) { if(lastItem.getText().equals("More Windows...")) { windowMenu.remove(lastItem); } } } break; } } windowMenu.revalidate(); } | 47609 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47609/b9766e81693411fa600b26b9a0763dcf621b2770/Main.java/clean/js/rhino/toolsrc/org/mozilla/javascript/tools/debugger/Main.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
1206,
3829,
12,
812,
3829,
341,
13,
288,
3639,
585,
10399,
18,
4479,
12,
91,
18,
588,
1489,
10663,
3639,
804,
4599,
2742,
4599,
273,
26156,
4599,
5621,
3639,
509,
1056,
273,
2742,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
1206,
3829,
12,
812,
3829,
341,
13,
288,
3639,
585,
10399,
18,
4479,
12,
91,
18,
588,
1489,
10663,
3639,
804,
4599,
2742,
4599,
273,
26156,
4599,
5621,
3639,
509,
1056,
273,
2742,
... |
Start.main(args); } | Start.main(args); } | public static void main(String[] args) { Start.main(args); } | 45952 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45952/9bea173ad0684cd425c468d55310cccc5a96e8a0/Main.java/clean/src/java/org/apache/log4j/chainsaw/Main.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
288,
6647,
3603,
18,
5254,
12,
1968,
1769,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
288,
6647,
3603,
18,
5254,
12,
1968,
1769,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
destroyChild(rightOrganizer); | destroyChild(rightDisplayItem); | public void finalizz() throws Exception { Organizer rightOrganizer = (Organizer) getChild(SplitPane.RIGHT_ORGANIZER); removeChild(SplitPane.RIGHT_ORGANIZER); destroyChild(rightOrganizer); Organizer leftOrganizer = (Organizer) getChild(SplitPane.LEFT_ORGANIZER); removeChild(SplitPane.LEFT_ORGANIZER); destroyChild(leftOrganizer); super.finalizz(); } | 11597 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11597/c936ef6d18d8499795b8e74b59da3459da0d0b3c/SplitPane.java/buggy/trunk/src/core/cybop/core/screen/region/SplitPane.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
727,
25695,
1435,
1216,
1185,
288,
3639,
8533,
304,
1824,
2145,
6001,
304,
1824,
273,
261,
6001,
304,
1824,
13,
8154,
12,
5521,
8485,
18,
11847,
67,
25071,
1258,
6867,
654,
176... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
727,
25695,
1435,
1216,
1185,
288,
3639,
8533,
304,
1824,
2145,
6001,
304,
1824,
273,
261,
6001,
304,
1824,
13,
8154,
12,
5521,
8485,
18,
11847,
67,
25071,
1258,
6867,
654,
176... |
if (!loaded) { throw new IllegalStateException ("not loaded"); } if (keyring == null) { return null; } if (!(keyring instanceof IPublicKeyring)) { throw new IllegalStateException("not a public keyring"); } Enumeration aliases = keyring.aliases(); while (aliases.hasMoreElements()) | log.entering(this.getClass().getName(), "engineGetCertificateAlias", cert); ensureLoaded(); String result = null; for (Enumeration aliases = publicKR.aliases(); aliases.hasMoreElements();) | public String engineGetCertificateAlias(Certificate cert) { if (!loaded) { throw new IllegalStateException ("not loaded"); } if (keyring == null) { return null; } if (!(keyring instanceof IPublicKeyring)) { throw new IllegalStateException("not a public keyring"); } Enumeration aliases = keyring.aliases(); while (aliases.hasMoreElements()) { String alias = (String) aliases.nextElement(); Certificate cert2 = ((IPublicKeyring) keyring).getCertificate(alias); if (cert.equals(cert2)) { return alias; } } return null; } | 1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/abad947539d38da7392ff914207d1bb7d5538320/GnuKeyring.java/clean/core/src/classpath/gnu/gnu/javax/crypto/jce/keyring/GnuKeyring.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
514,
4073,
967,
4719,
2936,
12,
4719,
3320,
13,
225,
288,
565,
309,
16051,
4230,
13,
1377,
288,
3639,
604,
394,
5477,
7566,
902,
4203,
8863,
1377,
289,
565,
309,
261,
856,
8022,
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,
282,
1071,
514,
4073,
967,
4719,
2936,
12,
4719,
3320,
13,
225,
288,
565,
309,
16051,
4230,
13,
1377,
288,
3639,
604,
394,
5477,
7566,
902,
4203,
8863,
1377,
289,
565,
309,
261,
856,
8022,
4... |
public void startRecording() { | public synchronized void startRecording() { | public void startRecording() { changedProperties = new HashSet(); isRecording = true; } | 46029 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46029/7fadb9ce200c03af44273f0544e0ae746ac65eb2/GlobalObject.java/clean/src/helma/scripting/rhino/GlobalObject.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
918,
787,
21037,
1435,
288,
3639,
3550,
2297,
273,
394,
6847,
5621,
3639,
353,
21037,
273,
638,
31,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
918,
787,
21037,
1435,
288,
3639,
3550,
2297,
273,
394,
6847,
5621,
3639,
353,
21037,
273,
638,
31,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
public void setOwnerForProtectionElement(String userName, String protectionElementObjectId, String protectionElementAttributeName)throws CSTransactionException; | public void setOwnerForProtectionElement(String protectionElementObjectId, String[] userNames)throws CSTransactionException; | public void setOwnerForProtectionElement(String userName, String protectionElementObjectId, String protectionElementAttributeName)throws CSTransactionException; | 56056 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56056/175e655d33ef90d8b49fd6442feb23ee98b909f1/AuthorizationManager.java/clean/api/src/gov/nih/nci/security/AuthorizationManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
31309,
1290,
16938,
1046,
12,
780,
12065,
16,
514,
17862,
1046,
16661,
16,
514,
17862,
1046,
19240,
13,
15069,
385,
882,
28001,
1128,
503,
31,
2,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
31309,
1290,
16938,
1046,
12,
780,
12065,
16,
514,
17862,
1046,
16661,
16,
514,
17862,
1046,
19240,
13,
15069,
385,
882,
28001,
1128,
503,
31,
2,
-100,
-100,
-100,
-100,
-1... |
map.put(Constants.TOKEN_KEY, token); | results.put(Constants.TOKEN_KEY, token); | public static Map computeParameters(PageContext pageContext, String paramId, String paramName, String paramProperty, String paramScope, String name, String property, String scope, boolean transaction) throws JspException { // Short circuit if no parameters are specified if ((paramId == null) && (name == null)) return (null); // Locate the Map containing our multi-value parameters map Map map = null; try { map = (Map) lookup(pageContext, name, property, scope); } catch (ClassCastException e) { saveException(pageContext, e); throw new JspException (messages.getMessage("parameters.multi", name, property, scope)); } catch (JspException e) { saveException(pageContext, e); throw e; } // Create a Map to contain our results from the multi-value parameters Map results = null; if (map != null) results = new HashMap(map); else results = new HashMap(); // Add the single-value parameter (if any) if (paramId != null) { String paramValue = null; try { paramValue =(String) lookup(pageContext, paramName, paramProperty, paramScope); } catch (ClassCastException e) { saveException(pageContext, e); throw new JspException (messages.getMessage("parameters.single", paramName, paramProperty, paramScope)); } catch (JspException e) { saveException(pageContext, e); throw e; } Object mapValue = map.get(paramId); if (mapValue == null) map.put(paramId, paramValue); else if (mapValue instanceof String) { String newValues[] = new String[2]; newValues[0] = (String) mapValue; newValues[1] = paramValue; map.put(paramId, newValues); } else /* if (mapValue instanceof String[]) */ { String oldValues[] = (String[]) mapValue; String newValues[] = new String[oldValues.length + 1]; System.arraycopy(oldValues, 0, newValues, 0, oldValues.length); newValues[oldValues.length] = paramValue; map.put(paramId, newValues); } } // Add our transaction control token (if requested) if (transaction) { HttpSession session = pageContext.getSession(); String token = null; if (session != null) token = (String) session.getAttribute(Action.TRANSACTION_TOKEN_KEY); if (token != null) map.put(Constants.TOKEN_KEY, token); } // Return the completed Map return (results); } | 48068 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48068/03a3c2a8c9d61f06867cede5a5063d6bd048a09c/RequestUtils.java/buggy/src/share/org/apache/struts/util/RequestUtils.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1635,
3671,
2402,
12,
1964,
1042,
21442,
16,
4766,
3639,
514,
579,
548,
16,
514,
11466,
16,
4766,
3639,
514,
579,
1396,
16,
4766,
3639,
514,
579,
3876,
16,
514,
508,
16,
4766... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1635,
3671,
2402,
12,
1964,
1042,
21442,
16,
4766,
3639,
514,
579,
548,
16,
514,
11466,
16,
4766,
3639,
514,
579,
1396,
16,
4766,
3639,
514,
579,
3876,
16,
514,
508,
16,
4766... |
clipboard = new Clipboard(parent.getDisplay()); | clipboard = new Clipboard(parent.getDisplay()); | public void createPartControl(Composite parent) { clipboard = new Clipboard(parent.getDisplay()); super.createPartControl(parent); initDragAndDrop(); getSite().getPage().addSelectionListener(focusListener); focusSelectionChanged(getSite().getPage().getActivePart(), getSite() .getPage().getSelection()); ResourcesPlugin.getWorkspace().addResourceChangeListener( resourceListener); refresh(); // Set help on the view itself getViewer().getControl().addHelpListener(new HelpListener() { /* * (non-Javadoc) * @see org.eclipse.swt.events.HelpListener#helpRequested(org.eclipse.swt.events.HelpEvent) */ public void helpRequested(HelpEvent e) { IContext context = contextProvider.getContext(getViewer().getControl()); PlatformUI.getWorkbench().getHelpSystem() .displayHelp(context); } }); } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/1ceb585b9b16047c6c580984b0c9962c41a22ba6/MarkerView.java/clean/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/MarkerView.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
752,
1988,
3367,
12,
9400,
982,
13,
288,
3639,
20304,
273,
394,
385,
3169,
3752,
12,
2938,
18,
588,
4236,
10663,
3639,
2240,
18,
2640,
1988,
3367,
12,
2938,
1769,
3639,
1208,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
752,
1988,
3367,
12,
9400,
982,
13,
288,
3639,
20304,
273,
394,
385,
3169,
3752,
12,
2938,
18,
588,
4236,
10663,
3639,
2240,
18,
2640,
1988,
3367,
12,
2938,
1769,
3639,
1208,
... |
public void setFlags(MessageInfo[] msgs, Flags flag, boolean value) throws MessagingException { Message[] m = new Message[msgs.length]; for (int i = 0; i < msgs.length; i++) { m[i] = msgs[i].getRealMessage(); } getFolder().setFlags(m, flag, value); } | 967 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/967/6d6ba90375f9de34e58b248daf5e8c0025c1433b/FolderInfo.java/buggy/src/net/suberic/pooka/FolderInfo.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
444,
5094,
12,
1079,
966,
8526,
8733,
16,
10104,
2982,
16,
1250,
460,
13,
1216,
23794,
503,
288,
565,
2350,
8526,
312,
273,
394,
2350,
63,
27439,
18,
2469,
15533,
565,
364,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
444,
5094,
12,
1079,
966,
8526,
8733,
16,
10104,
2982,
16,
1250,
460,
13,
1216,
23794,
503,
288,
565,
2350,
8526,
312,
273,
394,
2350,
63,
27439,
18,
2469,
15533,
565,
364,
2... | ||
return RubyString.newString(getRuntime(), method.getName()); | return getRuntime().newString(method.getName()); | public RubyString name() { return RubyString.newString(getRuntime(), method.getName()); } | 46217 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46217/870e1da9b41bfdbae259e1fc5f18fc8b76686998/JavaMethod.java/clean/src/org/jruby/javasupport/JavaMethod.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
19817,
780,
508,
1435,
288,
3639,
327,
18814,
7675,
2704,
780,
12,
2039,
18,
17994,
10663,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
19817,
780,
508,
1435,
288,
3639,
327,
18814,
7675,
2704,
780,
12,
2039,
18,
17994,
10663,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
public org.quickfix.field.UnderlyingRepoCollateralSecurityType getUnderlyingRepoCollateralSecurityType() throws FieldNotFound { org.quickfix.field.UnderlyingRepoCollateralSecurityType value = new org.quickfix.field.UnderlyingRepoCollateralSecurityType(); | public quickfix.field.UnderlyingRepoCollateralSecurityType getUnderlyingRepoCollateralSecurityType() throws FieldNotFound { quickfix.field.UnderlyingRepoCollateralSecurityType value = new quickfix.field.UnderlyingRepoCollateralSecurityType(); | public org.quickfix.field.UnderlyingRepoCollateralSecurityType getUnderlyingRepoCollateralSecurityType() throws FieldNotFound { org.quickfix.field.UnderlyingRepoCollateralSecurityType value = new org.quickfix.field.UnderlyingRepoCollateralSecurityType(); getField(value); return value; } | 8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/TradeCaptureReport.java/buggy/src/java/src/quickfix/fix44/TradeCaptureReport.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
14655,
6291,
8791,
13535,
2045,
287,
4368,
559,
10833,
765,
6291,
8791,
13535,
2045,
287,
4368,
559,
1435,
1216,
2286,
2768,
225,
288,
2358,
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,
14655,
6291,
8791,
13535,
2045,
287,
4368,
559,
10833,
765,
6291,
8791,
13535,
2045,
287,
4368,
559,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
... |
Query q3 = new Query(); | q3 = new Query(); | public void testQuiteComplexQuery() throws Exception { Query q1 = new Query("select t1.field1 as first, table2.field1, count(*) as c, max(t1.field2) as mx from table1 t1, table2, (select table3.field2 as f1 from table3) as t3 where t1.field3 = table2.field1 and t3.f1 = table2.field3 and (t1.field4 = table2.field2 or t1.field4 = table2.field3) group by t1.field1, table2.field1 having (t1.field1 = table2.field2 or t1.field1 = table2.field3) order by t1.field1, table2.field1 limit 100 offset 10"); Query q2 = new Query(); Table t1 = new Table("table1", "t1"); Table t2 = new Table("table2"); Table t3 = new Table("table3"); Field t1f1 = new Field("field1", t1); Field t1f2 = new Field("field2", t1); Field t1f3 = new Field("field3", t1); Field t1f4 = new Field("field4", t1); Field t2f1 = new Field("field1", t2); Field t2f2 = new Field("field2", t2); Field t2f3 = new Field("field3", t2); Field t3f2 = new Field("field2", t3); Query q3 = new Query(); q3.addSelect(new SelectValue(t3f2, "f1")); q3.addFrom(t3); SubQuery sq1 = new SubQuery(q3, "t3"); Field t3f1 = new Field("f1", sq1); SelectValue sv1 = new SelectValue(t1f1, "first"); SelectValue sv2 = new SelectValue(t2f1, null); SelectValue sv3 = new SelectValue(new Function(Function.COUNT), "c"); Function func1 = new Function(Function.MAX); func1.add(t1f2); SelectValue sv4 = new SelectValue(func1, "mx"); ConstraintSet cs1 = new ConstraintSet(); cs1.add(new Constraint(t1f4, Constraint.EQ, t2f2)); cs1.add(new Constraint(t1f4, Constraint.EQ, t2f3)); ConstraintSet cs2 = new ConstraintSet(); cs2.add(new Constraint(t1f1, Constraint.EQ, t2f2)); cs2.add(new Constraint(t1f1, Constraint.EQ, t2f3)); q2.addSelect(sv1); q2.addSelect(sv2); q2.addSelect(sv3); q2.addSelect(sv4); q2.addFrom(t1); q2.addFrom(t2); q2.addFrom(sq1); q2.addWhere(new Constraint(t1f3, Constraint.EQ, t2f1)); q2.addWhere(new Constraint(t2f3, Constraint.EQ, t3f1)); q2.addWhere(cs1); q2.addGroupBy(t1f1); q2.addGroupBy(t2f1); q2.addHaving(cs2); q2.addOrderBy(t1f1); q2.addOrderBy(t2f1); q2.setLimitOffset(100,10); assertEquals(q2, q1); } | 29158 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/29158/a5e9331f55149bdc78aa8770ceaec1bc56d8e9dd/QueryTest.java/buggy/intermine/src/test/org/intermine/sql/query/QueryTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
928,
1137,
12795,
1138,
1435,
1216,
1185,
288,
3639,
2770,
1043,
21,
273,
394,
2770,
2932,
4025,
268,
21,
18,
1518,
21,
487,
1122,
16,
1014,
22,
18,
1518,
21,
16,
1056,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
928,
1137,
12795,
1138,
1435,
1216,
1185,
288,
3639,
2770,
1043,
21,
273,
394,
2770,
2932,
4025,
268,
21,
18,
1518,
21,
487,
1122,
16,
1014,
22,
18,
1518,
21,
16,
1056,... |
public boolean notEmptyAndNotDub(String s){ | public boolean notEmptyAndNotDub(String s,boolean newItem){ | public boolean notEmptyAndNotDub(String s){ //if name=assessment name List return true else return false AssessmentService assessmentService = new AssessmentService(); boolean returnValue=true; try{ ArrayList list = assessmentService.getBasicInfoOfAllActiveAssessments("title"); Iterator iter = list.iterator(); while (iter.hasNext()){ AssessmentFacade facade =(AssessmentFacade) iter.next(); String n=facade.getTitle(); System.out.println("AssessmentName: "+n); if((s==null)||((s.trim()).equals(""))||((s.trim()).equals(n.trim()))){ returnValue= false; break; } } } catch(Exception e){ e.printStackTrace(); throw new Error(e); } return returnValue; } | 2021 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2021/815c9389292fc5251777e54b1e63721c9fed6d64/SaveAssessmentSettings.java/buggy/samigo/tool/src/java/org/sakaiproject/tool/assessment/ui/listener/author/SaveAssessmentSettings.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1250,
21263,
1876,
1248,
40,
373,
12,
780,
272,
15329,
202,
759,
430,
508,
33,
18222,
508,
987,
327,
638,
469,
327,
629,
3639,
25241,
1179,
14158,
1179,
273,
394,
25241,
1179,
5621,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1250,
21263,
1876,
1248,
40,
373,
12,
780,
272,
15329,
202,
759,
430,
508,
33,
18222,
508,
987,
327,
638,
469,
327,
629,
3639,
25241,
1179,
14158,
1179,
273,
394,
25241,
1179,
5621,... |
vcs.createFile(p("file2"), null); | vcs.createFile(p("/file2"), null); | public void testRevertingSeveralTimesRunning() { vcs.createFile(p("file1"), null); vcs.apply(); vcs.createFile(p("file2"), null); vcs.apply(); assertTrue(vcs.hasEntry(p("file1"))); assertTrue(vcs.hasEntry(p("file2"))); vcs._revert(); assertTrue(vcs.hasEntry(p("file1"))); assertFalse(vcs.hasEntry(p("file2"))); vcs._revert(); assertFalse(vcs.hasEntry(p("file1"))); assertFalse(vcs.hasEntry(p("file2"))); } | 17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/8a6fdbc15b3cd4aaa232cf2026aa4a60418c162a/LocalVcsBasicsTest.java/clean/LocalVcs/test/com/intellij/localvcs/LocalVcsBasicsTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
1842,
426,
1097,
310,
1761,
502,
287,
10694,
7051,
1435,
288,
565,
20255,
18,
2640,
812,
12,
84,
2932,
768,
21,
6,
3631,
446,
1769,
565,
20255,
18,
9010,
5621,
565,
20255,
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,
918,
1842,
426,
1097,
310,
1761,
502,
287,
10694,
7051,
1435,
288,
565,
20255,
18,
2640,
812,
12,
84,
2932,
768,
21,
6,
3631,
446,
1769,
565,
20255,
18,
9010,
5621,
565,
20255,
18... |
switch (token.getType()) { case Token.NUMBER: return factory.newLiteral(parseValue(token.getValue())); | switch (token.getType()) { case Token.NUMBER: return factory.newLiteral(parseValue(token.getValue())); | private Expression parseValExpr( Lexer lexer ) throws ParseException, IOException { Token token = lexer.nextToken(); switch (token.getType()) { case Token.NUMBER: return factory.newLiteral(parseValue(token.getValue())); case Token.IDENTIFIER: return factory.newVariableReference(token.getValue()); case Token.PAREN_OPEN: { Expression result = parseExpression(lexer); if (lexer.nextToken().getType() != Token.PAREN_CLOSE) { throw new ParseException("closing parenthesis missing"); } return result; } case Token.END: throw new ParseException("unexpected end of input"); default: throw new ParseException("unexpected token \"" + token.getValue() + "\""); } } | 2796 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2796/a917aff361c58c31c5dce12a5e8052df6803dbe1/InfixParser.java/buggy/jmock/examples/calculator/src/org/jmock/examples/calculator/InfixParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
5371,
1109,
3053,
4742,
12,
14234,
8512,
262,
202,
3639,
1216,
10616,
16,
1860,
288,
202,
202,
1345,
1147,
273,
8512,
18,
4285,
1345,
5621,
202,
202,
9610,
261,
2316,
18,
588,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
5371,
1109,
3053,
4742,
12,
14234,
8512,
262,
202,
3639,
1216,
10616,
16,
1860,
288,
202,
202,
1345,
1147,
273,
8512,
18,
4285,
1345,
5621,
202,
202,
9610,
261,
2316,
18,
588,
... |
for(int i = nbrOfCols+1; i<DBArr.length; i += nbrOfCols) { String oneParsedRecordStr = "" ; Vector dataV = new Vector() ; | for(int i = nbrOfCols+1; i<DBArr.length; i += nbrOfCols) { String oneParsedRecordStr = "" ; Vector dataV = new Vector() ; | public String preParse (HttpServletRequest req, String[] DBArr, Vector tagsV, File htmlCodeFile, String imagePath) throws ServletException, IOException { StringBuffer htmlStr = new StringBuffer("") ; try { // Lets get the url to the servlets directory String servletHome = MetaInfo.getServletPath(req) ; // Lets get the part of the expert html File templateLib = super.getExternalTemplateFolder(req) ; // Lets get the nbr of cols int nbrOfCols = Integer.parseInt(DBArr[0]) ; //log("Number of cols: " + nbrOfCols) ; // Lets build an tagsArray with the tags from the DBarr, if // null was passed to us instead of a vector if( tagsV == null) { tagsV = new Vector() ; for(int k = 1; k<nbrOfCols; k++) { tagsV.add(DBArr[k]) ; // log("Counter: "+ k + " Tagvrde: " + DBArr[k] ) ; } } // Lets do for all records... for(int i = nbrOfCols+1; i<DBArr.length; i += nbrOfCols) { String oneParsedRecordStr = "" ; Vector dataV = new Vector() ; for(int j=i; j<i+nbrOfCols ; j++) { dataV.add(DBArr[j]) ; } htmlStr.append(this.parseOneRecord(tagsV, dataV, htmlCodeFile)); // log("Ett record: " + oneParsedRecordStr); } // end of the big for } catch(Exception e) { log("Error in Preparse") ; return null ; } return htmlStr.toString() ; } // End of | 8781 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8781/a270627916b37a677a391dd9f45c54d3d6f12503/BillBoardReply.java/buggy/servlets/billBoard/BillBoardReply.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
675,
3201,
261,
2940,
18572,
1111,
16,
514,
8526,
2383,
5715,
16,
5589,
2342,
58,
16,
202,
202,
812,
1729,
1085,
812,
16,
514,
29181,
13,
225,
1216,
16517,
16,
1860,
288,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
514,
675,
3201,
261,
2940,
18572,
1111,
16,
514,
8526,
2383,
5715,
16,
5589,
2342,
58,
16,
202,
202,
812,
1729,
1085,
812,
16,
514,
29181,
13,
225,
1216,
16517,
16,
1860,
288,... |
AvailableDbObjects.removeAll(); | availableDbObjectsTree.removeAll(); | protected void populateTableList() { // Remove all the existing children of the root Node if ( rootNode != null ) { AvailableDbObjects.removeAll(); setRootElement(); } String namePattern = null; String[] tableType = null; if ( searchTxt.getText().length() > 0 ) { namePattern = searchTxt.getText(); // Add the % by default if there is no such pattern if ( namePattern != null ) { if ( namePattern.lastIndexOf('%') == -1) { namePattern = namePattern + "%"; } } } String dbtype = getSelectedDbType(); if ( dbtype != null && ! DbType.ALL_STRING.equalsIgnoreCase(dbtype)) { tableType = new String[]{ dbtype }; } String catalogName = metaDataProvider.getCatalog(); ArrayList tableList = new ArrayList(); if (schemaList != null && schemaList.size() > 0) { ResultSet tablesRs = null; // For each schema Get the List of Tables int numTables = 0; boolean maxRecordsDisplayed = false; for( int i=0; i< schemaList.size(); i++) { if ( maxRecordsDisplayed ) { break; } int count = 0; String schemaName = (String)schemaList.get(i); tablesRs = metaDataProvider.getAlltables(catalogName,schemaName,namePattern,tableType); tableList = new ArrayList(); if( tablesRs == null ) { continue; } try { // Create the schema Node ArrayList schema = new ArrayList(); TreeItem schemaTreeItem[] = null; int tableCount = 0; Image image = tableImage; while( tablesRs.next()) { if( count == 0 ) { schema.add(schemaName); schemaTreeItem = Utility.createTreeItems(rootNode, schema, SWT.NONE, schemaImage); } count++; String SchemaName = tablesRs.getString("TABLE_SCHEM");//$NON-NLS-1$ String tableName = tablesRs.getString("TABLE_NAME");//$NON-NLS-1$ String type = tablesRs.getString("TABLE_TYPE");//$NON-NLS-1$ int dbType = DbObject.TABLE_TYPE; if(type.equalsIgnoreCase("TABLE")) { image = tableImage; dbType = DbObject.TABLE_TYPE; } else if(type.equalsIgnoreCase("VIEW")) { image = viewImage; dbType = DbObject.VIEW_TYPE; } String fullyQualifiedTableName = tableName; if( schemaName != null && schemaName.trim().length() > 0) { fullyQualifiedTableName = schemaName + "." + tableName; } DbObject dbObject = new DbObject(fullyQualifiedTableName,tableName, dbType, image); tableList.add(dbObject); numTables ++; if ( numTables == DbType.MAX_ITEMS_DISPLAY_COUNT ) { maxRecordsDisplayed = true; break; } } if( schemaTreeItem != null && schemaTreeItem.length > 0) { TreeItem item[] = Utility.createTreeItems(schemaTreeItem[0], tableList, SWT.NONE, null); schemaTreeItem[0].setExpanded(false); } } catch(SQLException e) { e.printStackTrace(); } } checkForMaxRecordsDisplayed(maxRecordsDisplayed, tablesRs); } else { //ResultSet tablesRs = metaDataProvider.getAlltables(catalogName,null,namePattern,tableType); ResultSet tablesRs = metaDataProvider.getAlltables(catalogName,null,namePattern,tableType); if( tablesRs == null) { return; } int count = 0; boolean maxRecordsDisplayed = false; try { Image image = tableImage; while( tablesRs.next()) { count ++; String SchemaName = tablesRs.getString("TABLE_SCHEM");//$NON-NLS-1$ String tableName = tablesRs.getString("TABLE_NAME");//$NON-NLS-1$ String type = tablesRs.getString("TABLE_TYPE");//$NON-NLS-1$ int dbType = DbObject.TABLE_TYPE; if(type.equalsIgnoreCase("TABLE")) { image = tableImage; dbType = DbObject.TABLE_TYPE; } else if(type.equalsIgnoreCase("VIEW")) { image = viewImage; dbType = DbObject.VIEW_TYPE; } DbObject dbObject = new DbObject(tableName, tableName,dbType, image); tableList.add(dbObject); if ( count == DbType.MAX_ITEMS_DISPLAY_COUNT ) { maxRecordsDisplayed = true; break; } } TreeItem item[] = Utility.createTreeItems(rootNode, tableList, SWT.NONE, null); // Add listener to display the column names when expanded checkForMaxRecordsDisplayed(maxRecordsDisplayed, tablesRs); } catch(Exception e) { e.printStackTrace(); } } // Add a listener for fetching columns addFetchColumnListener(); } | 12803 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12803/fdb840ed0d1bd5738d66f7ef3495e6f3b896fe6d/SQLDataSetEditorPage.java/clean/data/org.eclipse.birt.report.data.oda.jdbc.ui/src/org/eclipse/birt/report/data/oda/jdbc/ui/editors/SQLDataSetEditorPage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
6490,
1388,
682,
1435,
202,
95,
1082,
368,
3581,
777,
326,
2062,
2325,
434,
326,
1365,
2029,
1082,
309,
261,
10181,
480,
446,
262,
1082,
288,
1082,
225,
202,
5268,
4331,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6490,
1388,
682,
1435,
202,
95,
1082,
368,
3581,
777,
326,
2062,
2325,
434,
326,
1365,
2029,
1082,
309,
261,
10181,
480,
446,
262,
1082,
288,
1082,
225,
202,
5268,
4331,
... |
return myDateFormat.format(new Date()) + " [MD]"; | return Default.getDate() + " [MD]"; | static String getNormalDate() { return myDateFormat.format(new Date()) + " [MD]"; } | 5620 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5620/d1ef79fafdbbeaaf4dcbaa9d3c534754c217d955/WriteCollationData.java/clean/tools/unicodetools/com/ibm/text/UCA/WriteCollationData.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
760,
514,
336,
5506,
1626,
1435,
288,
3639,
327,
2989,
18,
588,
1626,
1435,
397,
315,
306,
6188,
4279,
31,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
760,
514,
336,
5506,
1626,
1435,
288,
3639,
327,
2989,
18,
588,
1626,
1435,
397,
315,
306,
6188,
4279,
31,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
if (immediateServices.contains(methodName)) { return true; } else { return false; | if (logger.isDebugEnabled()) { logger.debug("immediateExecution for methode " + methodName + " is " + immediateServices.contains(methodName)); | private boolean immediateExecution(String methodName) { if (immediateServices.contains(methodName)) { return true; } else { return false; } } | 14315 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/14315/c171c3550f70b496c1228bbed45f5f8feea45a9c/RequestReceiverImpl.java/clean/src/org/objectweb/proactive/core/body/request/RequestReceiverImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1250,
14483,
3210,
12,
780,
4918,
13,
288,
3639,
309,
261,
381,
6785,
5676,
18,
12298,
12,
2039,
461,
3719,
288,
5411,
327,
638,
31,
3639,
289,
469,
288,
5411,
327,
629,
31,
3639,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3238,
1250,
14483,
3210,
12,
780,
4918,
13,
288,
3639,
309,
261,
381,
6785,
5676,
18,
12298,
12,
2039,
461,
3719,
288,
5411,
327,
638,
31,
3639,
289,
469,
288,
5411,
327,
629,
31,
3639,... |
throws InlinePragma { | throws InlinePragma { | public ObjectReference precopyObject(ObjectReference object) throws InlinePragma { if (Assert.VERIFY_ASSERTIONS) { // All precopying must occur during the initial trace. Assert._assert(!Space.isInSpace(MC.MARK_COMPACT, object)); } return super.precopyObject(object); } | 5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/4c66aa27cec27f8dd5902baec018ff86d7f49ee2/MCForwardTraceLocal.java/clean/MMTk/src/org/mmtk/plan/markcompact/MCForwardTraceLocal.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
31321,
675,
3530,
921,
12,
22101,
733,
13,
565,
1216,
16355,
2050,
9454,
288,
565,
309,
261,
8213,
18,
23756,
67,
8423,
11539,
1146,
55,
13,
288,
1377,
368,
4826,
675,
3530,
310,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
31321,
675,
3530,
921,
12,
22101,
733,
13,
565,
1216,
16355,
2050,
9454,
288,
565,
309,
261,
8213,
18,
23756,
67,
8423,
11539,
1146,
55,
13,
288,
1377,
368,
4826,
675,
3530,
310,
... |
new TableLayoutConstraints(0, 8, 0, 8, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( | new TableLayoutConstraints(0, 8, 0, 8, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER) ); mFrameBufferPanel.add( | private void jbInit() throws Exception { // Columns are as follows: // 0 -> panel start // 1 -> window name label // 2 -> spacer between window name label and window name field // 3 -> window name field start, lame space for mResourceChooser // 4 -> window name field end // 5 -> panel end double[][] main_size = { {5, TableLayout.MINIMUM, 5, 300, TableLayout.FILL, 5}, {TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED} }; mMainLayout = new TableLayout(main_size); double[][] bounds_size = { {TableLayout.PREFERRED, TableLayout.PREFERRED}, {TableLayout.PREFERRED, TableLayout.PREFERRED} }; mBoundsPanelLayout = new TableLayout(bounds_size); double[][] fb_size = { {TableLayout.MINIMUM, 5, TableLayout.PREFERRED}, {TableLayout.PREFERRED} }; mFrameBufferPanelLayout = new TableLayout(fb_size); double[][] fb_settings_size = { {TableLayout.FILL, TableLayout.PREFERRED}, {TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED} }; mFBSettingsLayout = new TableLayout(fb_settings_size); // Colums are as follows: // 0 -> editor label // 1 -> spacer betweeen label and editor // 2 -> start for lock key and sleep time editors; end for checkbox // editor // 3 -> end for sleep time editor // 4 -> spacer between sleep time editor and sleep time units label // 5 -> end for lock key editor; unit label for sleep time editor // // NOTE: Column 2 is a hack to make it appear as though the check box // is two separate UI components. double[][] window_props_size = { {TableLayout.PREFERRED, 5, 20, TableLayout.MINIMUM, 5, TableLayout.MINIMUM}, {TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED, TableLayout.PREFERRED} }; mWindowPropsPanelLayout = new TableLayout(window_props_size); mBoundsPanelBorder = new TitledBorder( BorderFactory.createEtchedBorder(Color.white, new Color(161, 161, 161)), "Window Bounds" ); mFrameBufferPanelBorder = new TitledBorder( BorderFactory.createEtchedBorder(Color.white, new Color(142, 142, 142)), "Visual Quality Settings" ); mWindowPropsPanelBorder = new TitledBorder( BorderFactory.createEtchedBorder(Color.white, new Color(142, 142, 142)), "Window Behavior Settings" ); mFBSettingsPanelBorder = new EtchedBorder(EtchedBorder.RAISED, Color.white, new Color(142, 142, 142)); mMainPanel.setLayout(mMainLayout); mResourceLabel.setHorizontalAlignment(SwingConstants.TRAILING); mResourceLabel.setLabelFor(mResourceChooser); mResourceLabel.setText("Resource"); mNameLabel.setHorizontalAlignment(SwingConstants.TRAILING); mNameLabel.setLabelFor(mNameField); mNameLabel.setText("Window Name"); mNameField.setMinimumSize(new Dimension(60, 21)); mNameField.setPreferredSize(new Dimension(60, 21)); mNameField.setText("Display Window"); mSizeLabel.setHorizontalAlignment(SwingConstants.TRAILING); mSizeLabel.setLabelFor(mSizePanel); mSizeLabel.setText("Size"); mPositionLabel.setHorizontalAlignment(SwingConstants.TRAILING); mPositionLabel.setLabelFor(mPositionPanel); mPositionLabel.setText("Position"); mWidthField.setMinimumSize(new Dimension(50, 21)); mWidthField.setPreferredSize(new Dimension(50, 21)); mWidthField.setValue(new Integer(200)); mWidthField.setHorizontalAlignment(SwingConstants.TRAILING); mSizeXLabel.setText("\u00D7"); mHeightField.setMinimumSize(new Dimension(50, 21)); mHeightField.setPreferredSize(new Dimension(50, 21)); mHeightField.setValue(new Integer(200)); mPositionXField.setMinimumSize(new Dimension(40, 21)); mPositionXField.setPreferredSize(new Dimension(40, 21)); mPositionXField.setValue(new Integer(0)); mPositionXField.setHorizontalAlignment(SwingConstants.TRAILING); mPositionXLabel.setText(","); mPositionYField.setMinimumSize(new Dimension(40, 21)); mPositionYField.setPreferredSize(new Dimension(40, 21)); mPositionYField.setValue(new Integer(0)); mPositionYField.setHorizontalAlignment(SwingConstants.TRAILING); mFBSettingsLabel.setHorizontalAlignment(SwingConstants.TRAILING); mFBSettingsLabel.setLabelFor(mFBSettingsPanel); mFBSettingsLabel.setText("OpenGL Frame Buffer Settings"); mFBSettingsPanel.setLayout(mFBSettingsLayout); mRedDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mRedDepthLabel.setLabelFor(mRedDepthSpinner); mRedDepthLabel.setText("Red Depth"); mGreenDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mGreenDepthLabel.setLabelFor(mGreenDepthSpinner); mGreenDepthLabel.setText("Green Depth"); mBlueDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mBlueDepthLabel.setLabelFor(mBlueDepthSpinner); mBlueDepthLabel.setText("Blue Depth"); mAlphaDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mAlphaDepthLabel.setLabelFor(mAlphaDepthSpinner); mAlphaDepthLabel.setText("Alpha Depth"); mNumAuxBufferLabel.setHorizontalAlignment(SwingConstants.TRAILING); mNumAuxBufferLabel.setLabelFor(mNumAuxBufferSpinner); mNumAuxBufferLabel.setText("Number of Auxiliary Buffers"); mDepthBufferLabel.setHorizontalAlignment(SwingConstants.TRAILING); mDepthBufferLabel.setLabelFor(mDepthBufferSpinner); mDepthBufferLabel.setText("Depth Buffer Size"); mStencilBufferLabel.setHorizontalAlignment(SwingConstants.TRAILING); mStencilBufferLabel.setLabelFor(mStencilBufferSpinner); mStencilBufferLabel.setText("Stencil Buffer Size"); mAccumRedDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mAccumRedDepthLabel.setLabelFor(mAccumRedDepthSpinner); mAccumRedDepthLabel.setText("Accumulation Red Depth"); mAccumGreenDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mAccumGreenDepthLabel.setLabelFor(mAccumGreenDepthSpinner); mAccumGreenDepthLabel.setText("Accumulation Green Depth"); mAccumBlueDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mAccumBlueDepthLabel.setLabelFor(mAccumBlueDepthSpinner); mAccumBlueDepthLabel.setText("Accumulation Blue Depth"); mAccumAlphaDepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); mAccumAlphaDepthLabel.setLabelFor(mAccumAlphaDepthSpinner); mAccumAlphaDepthLabel.setText("Accumulation Alpha Depth"); mBorderCheckbox.setHorizontalTextPosition(SwingConstants.LEFT); mBorderCheckbox.setSelected(true); mBorderCheckbox.setText("Has border"); mStereoCheckbox.setHorizontalTextPosition(SwingConstants.LEFT); mStereoCheckbox.setText("Render in stereo"); mHideMouseCheckbox.setHorizontalTextPosition(SwingConstants.LEFT); mHideMouseCheckbox.setText("Hide mouse inside window"); mKbdDevLabel.setHorizontalAlignment(SwingConstants.TRAILING); mKbdDevLabel.setText("Keyboard/Mouse"); mLockKeyLabel.setHorizontalAlignment(SwingConstants.TRAILING); mLockKeyLabel.setText("Lock Key"); mStartLockedCB.setText("Start Locked"); mStartLockedCB.setHorizontalTextPosition(SwingConstants.LEFT); mSleepTimeLabel.setHorizontalAlignment(SwingConstants.TRAILING); mSleepTimeLabel.setLabelFor(mSleepTimeField); mSleepTimeLabel.setText("Sleep Time"); mSleepTimeField.setHorizontalAlignment(SwingConstants.RIGHT); mSleepMSLabel.setText("ms"); mOkButton.setEnabled(false); mOkButton.setMnemonic('0'); mOkButton.setSelected(false); mOkButton.setText("OK"); mOkButton.addActionListener( new DisplayWindowStartDialog_mOkButton_actionAdapter(this) ); mCancelButton.setMnemonic('0'); mCancelButton.setText("Cancel"); mCancelButton.addActionListener( new DisplayWindowStartDialog_mCancelButton_actionAdapter(this) ); mHelpButton.setEnabled(false); mHelpButton.setMnemonic('0'); mHelpButton.setText("Help"); mHelpButton.addActionListener( new DisplayWindowStartDialog_mHelpButton_actionAdapter(this) ); mFSAACheckbox.setText("Enable full-screen anti-aliasing"); mBoundsPanel.setLayout(mBoundsPanelLayout); mBoundsPanel.setBorder(mBoundsPanelBorder); mFrameBufferPanel.setLayout(mFrameBufferPanelLayout); mFrameBufferPanel.setBorder(mFrameBufferPanelBorder); mWindowPropsPanel.setLayout(mWindowPropsPanelLayout); mWindowPropsPanel.setBorder(mWindowPropsPanelBorder); mFBSettingsPanel.setBorder(mFBSettingsPanelBorder); mButtonPanel.setLayout(mButtonPanelLayout); mVisualIdLabel.setHorizontalAlignment(SwingConstants.TRAILING); mVisualIdLabel.setLabelFor(mVisualIdField); mVisualIdLabel.setText("Visual ID"); mVisualIdField.setMinimumSize(new Dimension(19, 20)); mVisualIdField.setPreferredSize(new Dimension(28, 20)); mVisualIdField.setToolTipText( "Enter a GLX or WGL visual ID in hexadecimal notation or -1 to ignore" ); mVisualIdField.setText("-1"); mVisualIdField.addActionListener( new DisplayWindowStartDialog_mVisualIdField_actionAdapter(this) ); mVisualIdField.addFocusListener( new DisplayWindowStartDialog_mVisualIdField_focusAdapter(this) ); this.getContentPane().add(mMainPanel, BorderLayout.CENTER); mBoundsPanel.add( mSizeLabel, new TableLayoutConstraints(0, 0, 0, 0, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER) ); mBoundsPanel.add( mSizePanel, new TableLayoutConstraints(1, 0, 1, 0, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER) ); mBoundsPanel.add( mPositionLabel, new TableLayoutConstraints(0, 1, 0, 1, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER) ); mBoundsPanel.add( mPositionPanel, new TableLayoutConstraints(1, 1, 1, 1, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER) ); mPositionPanel.add(mPositionXField, null); mPositionPanel.add(mPositionXLabel, null); mPositionPanel.add(mPositionYField, null); mSizePanel.add(mWidthField, null); mSizePanel.add(mSizeXLabel, null); mSizePanel.add(mHeightField, null); mFrameBufferPanel.setPreferredSize(new Dimension(450, 200)); mFrameBufferPanel.add( mFBSettingsLabel, new TableLayoutConstraints(0, 0, 0, 0, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER) ); mFrameBufferPanel.add( mFBSettingsPanel, new TableLayoutConstraints(2, 0, 2, 0, TableLayoutConstraints.FULL, TableLayoutConstraints.FULL) ); mFBSettingsPanel.add( mVisualIdLabel, new TableLayoutConstraints(0, 0, 0, 0, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mVisualIdField, new TableLayoutConstraints(1, 0, 1, 0, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mRedDepthLabel, new TableLayoutConstraints(0, 1, 0, 1, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mRedDepthSpinner, new TableLayoutConstraints(1, 1, 1, 1, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mGreenDepthLabel, new TableLayoutConstraints(0, 2, 0, 2, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mGreenDepthSpinner, new TableLayoutConstraints(1, 2, 1, 2, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mBlueDepthLabel, new TableLayoutConstraints(0, 3, 0, 3, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mBlueDepthSpinner, new TableLayoutConstraints(1, 3, 1, 3, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAlphaDepthLabel, new TableLayoutConstraints(0, 4, 0, 4, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAlphaDepthSpinner, new TableLayoutConstraints(1, 4, 1, 4, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mNumAuxBufferLabel, new TableLayoutConstraints(0, 5, 0, 5, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mNumAuxBufferSpinner, new TableLayoutConstraints(1, 5, 1, 5, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mDepthBufferLabel, new TableLayoutConstraints(0, 6, 0, 6, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mDepthBufferSpinner, new TableLayoutConstraints(1, 6, 1, 6, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mStencilBufferLabel, new TableLayoutConstraints(0, 7, 0, 7, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mStencilBufferSpinner, new TableLayoutConstraints(1, 7, 1, 7, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumRedDepthLabel, new TableLayoutConstraints(0, 8, 0, 8, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumRedDepthSpinner, new TableLayoutConstraints(1, 8, 1, 8, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumGreenDepthLabel, new TableLayoutConstraints(0, 9, 0, 9, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumGreenDepthSpinner, new TableLayoutConstraints(1, 9, 1, 9, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumBlueDepthLabel, new TableLayoutConstraints(0, 10, 0, 10, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumBlueDepthSpinner, new TableLayoutConstraints(1, 10, 1, 10, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumAlphaDepthLabel, new TableLayoutConstraints(0, 11, 0, 11, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mAccumAlphaDepthSpinner, new TableLayoutConstraints(1, 11, 1, 11, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mFBSettingsPanel.add( mFSAACheckbox, new TableLayoutConstraints(0, 12, 1, 12, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add(mBorderCheckbox, new TableLayoutConstraints(0, 0, 2, 0, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER)); mWindowPropsPanel.add(mStereoCheckbox, new TableLayoutConstraints(0, 1, 2, 1, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER)); mWindowPropsPanel.add(mHideMouseCheckbox, new TableLayoutConstraints(0, 2, 2, 2, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER)); mWindowPropsPanel.add( mKbdDevLabel, new TableLayoutConstraints(0, 3, 0, 3, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add( mKbdDevEditor, new TableLayoutConstraints(2, 3, 5, 3, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add( mLockKeyLabel, new TableLayoutConstraints(0, 4, 0, 4, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add( mLockKeyEditor, new TableLayoutConstraints(2, 4, 5, 4, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add( mStartLockedCB, new TableLayoutConstraints(0, 5, 2, 5, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add( mSleepTimeLabel, new TableLayoutConstraints(0, 6, 0, 6, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add( mSleepTimeField, new TableLayoutConstraints(2, 6, 3, 6, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER) ); mWindowPropsPanel.add( mSleepMSLabel, new TableLayoutConstraints(5, 6, 5, 6, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER) ); mMainPanel.add(mResourceLabel, new TableLayoutConstraints(1, 0, 1, 0, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER)); mMainPanel.add(mResourceChooser, new TableLayoutConstraints(3, 0, 3, 0, TableLayoutConstraints.LEFT, TableLayoutConstraints.CENTER)); mMainPanel.add(mNameLabel, new TableLayoutConstraints(1, 1, 1, 1, TableLayoutConstraints.RIGHT, TableLayoutConstraints.CENTER)); mMainPanel.add(mNameField, new TableLayoutConstraints(3, 1, 4, 1, TableLayoutConstraints.FULL, TableLayoutConstraints.CENTER)); mMainPanel.add(mBoundsPanel, new TableLayoutConstraints(0, 2, 5, 2, TableLayoutConstraints.FULL, TableLayoutConstraints.FULL)); mMainPanel.add(mFrameBufferPanel, new TableLayoutConstraints(0, 3, 5, 3, TableLayoutConstraints.FULL, TableLayoutConstraints.FULL)); mMainPanel.add(mWindowPropsPanel, new TableLayoutConstraints(0, 4, 5, 4, TableLayoutConstraints.FULL, TableLayoutConstraints.FULL)); this.getContentPane().add(mButtonPanel, BorderLayout.SOUTH); } | 49828 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49828/fde785be1019d3cddb692551eb1e534d790dd329/DisplayWindowStartDialog.java/clean/modules/vrjuggler/vrjconfig/customeditors/display_window/org/vrjuggler/vrjconfig/customeditors/display_window/DisplayWindowStartDialog.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
3238,
918,
20515,
2570,
1435,
1216,
1185,
282,
288,
1377,
368,
14962,
854,
487,
13040,
30,
1377,
368,
565,
374,
317,
6594,
787,
1377,
368,
565,
404,
317,
2742,
508,
1433,
1377,
368,
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,
565,
3238,
918,
20515,
2570,
1435,
1216,
1185,
282,
288,
1377,
368,
14962,
854,
487,
13040,
30,
1377,
368,
565,
374,
317,
6594,
787,
1377,
368,
565,
404,
317,
2742,
508,
1433,
1377,
368,
565,
... |
public org.quickfix.field.SecurityAltID get(org.quickfix.field.SecurityAltID value) | public quickfix.field.SecurityAltID get(quickfix.field.SecurityAltID value) | public org.quickfix.field.SecurityAltID get(org.quickfix.field.SecurityAltID value) throws FieldNotFound { getField(value); return value; } | 5926 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5926/fecc27f98261270772ff182a1d4dfd94b5daa73d/OrderCancelRequest.java/clean/src/java/src/quickfix/fix43/OrderCancelRequest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
9549,
904,
18,
1518,
18,
4368,
10655,
734,
336,
12,
19525,
904,
18,
1518,
18,
4368,
10655,
734,
225,
460,
13,
565,
1216,
2286,
2768,
225,
288,
5031,
12,
1132,
1769,
327,
460,
31,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
9549,
904,
18,
1518,
18,
4368,
10655,
734,
336,
12,
19525,
904,
18,
1518,
18,
4368,
10655,
734,
225,
460,
13,
565,
1216,
2286,
2768,
225,
288,
5031,
12,
1132,
1769,
327,
460,
31,
... |
Connection cx = getConnection(); dropTable("#t0009"); Statement stmt = cx.createStatement(); | Statement stmt = con.createStatement(); | public void testPreparedStatement0009() throws Exception { Connection cx = getConnection(); dropTable("#t0009"); Statement stmt = cx.createStatement(); stmt.executeUpdate("create table #t0009 " + " (i integer not null, " + " s char(10) not null) "); cx.setAutoCommit(false); PreparedStatement pStmt = cx.prepareStatement( "insert into #t0009 values (?, ?)"); int rowsToAdd = 8; final String theString = "abcdefghijklmnopqrstuvwxyz"; int count = 0; for (int i = 1; i <= rowsToAdd; i++) { pStmt.setInt(1, i); pStmt.setString(2, theString.substring(0, i)); count += pStmt.executeUpdate(); } pStmt.close(); assertEquals(count, rowsToAdd); cx.rollback(); stmt = cx.createStatement(); ResultSet rs = stmt.executeQuery("select s, i from #t0009"); assertNotNull(rs); count = 0; while (rs.next()) { count++; assertEquals(rs.getString(1).trim().length(), rs.getInt(2)); } assertEquals(count, 0); cx.commit(); stmt.close(); pStmt = cx.prepareStatement("insert into #t0009 values (?, ?)"); rowsToAdd = 6; count = 0; for (int i = 1; i <= rowsToAdd; i++) { pStmt.setInt(1, i); pStmt.setString(2, theString.substring(0, i)); count += pStmt.executeUpdate(); } assertEquals(count, rowsToAdd); cx.commit(); pStmt.close(); stmt = cx.createStatement(); rs = stmt.executeQuery("select s, i from #t0009"); count = 0; while (rs.next()) { count++; assertEquals(rs.getString(1).trim().length(), rs.getInt(2)); } assertEquals(count, rowsToAdd); cx.commit(); stmt.close(); cx.setAutoCommit(true); } | 5753 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5753/18b07ca9109fb5cb441d9af871c0106d9680227e/TimestampTest.java/buggy/src/test/net/sourceforge/jtds/test/TimestampTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
29325,
3784,
29,
1435,
1216,
1185,
288,
3639,
4050,
9494,
273,
6742,
5621,
3639,
3640,
1388,
2932,
7,
88,
3784,
29,
8863,
3639,
8056,
3480,
273,
9494,
18,
2640,
3406,
562... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
29325,
3784,
29,
1435,
1216,
1185,
288,
3639,
4050,
9494,
273,
6742,
5621,
3639,
3640,
1388,
2932,
7,
88,
3784,
29,
8863,
3639,
8056,
3480,
273,
9494,
18,
2640,
3406,
562... |
editor.getTextEditor().setCaretPosition(oldCaretPosition +caretOffset); | editor.getTextEditor().setCaretPosition(oldCaretPosition +caretOffset, false); | protected void replaceEditorTextAndAdjustCaretPosition(String newText) { int oldCaretPosition = editor.getTextPane().getCaretPosition(); String oldText = editor.getText(); int caretOffset = newText.length()-oldText.length(); editor.disableTextPaneUndo(); editor.getTextPane().setText(newText); editor.enableTextPaneUndo(); editor.getTextEditor().setCaretPosition(oldCaretPosition +caretOffset); } | 51505 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51505/3029d954794e560a3676aa391be237fe6c91f4af/ActionsRefactor.java/buggy/src/org/antlr/works/editor/actions/ActionsRefactor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
1453,
6946,
1528,
1876,
10952,
39,
20731,
2555,
12,
780,
394,
1528,
13,
288,
3639,
509,
1592,
39,
20731,
2555,
273,
4858,
18,
588,
1528,
8485,
7675,
588,
39,
20731,
2555,
5621,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
1453,
6946,
1528,
1876,
10952,
39,
20731,
2555,
12,
780,
394,
1528,
13,
288,
3639,
509,
1592,
39,
20731,
2555,
273,
4858,
18,
588,
1528,
8485,
7675,
588,
39,
20731,
2555,
5621,... |
if (base.getXSType() == XSTypeDecl.ANY_TYPE) base = SchemaGrammar.SG_SchemaNS.getGlobalTypeDecl(SchemaSymbols.ATTVAL_ANYSIMPLETYPE); | if (base == SchemaGrammar.fAnyType) base = SchemaGrammar.fAnySimpleType; | public static boolean checkSimpleDerivationOk(DatatypeValidator derived, XSTypeDecl base, int block) { // if derived is anySimpleType, then it's valid only if the base // is ur-type if (derived.getXSType() == XSTypeDecl.ANYSIMPLE_TYPE) return (base.getXSType() & XSTypeDecl.UR_TYPE) != 0; // if base is complex type if ((base.getXSType() & XSTypeDecl.COMPLEX_TYPE) != 0) { // if base is anyType, change base to anySimpleType, // otherwise, not valid if (base.getXSType() == XSTypeDecl.ANY_TYPE) base = SchemaGrammar.SG_SchemaNS.getGlobalTypeDecl(SchemaSymbols.ATTVAL_ANYSIMPLETYPE); else return false; } return checkSimpleDerivation((DatatypeValidator)derived, (DatatypeValidator)base, block); } | 6373 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6373/7d23b0f822620b832b611e0946e73bb880886a98/XSConstraints.java/clean/src/org/apache/xerces/impl/v2/XSConstraints.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1250,
866,
5784,
12041,
8482,
8809,
12,
20228,
5126,
10379,
16,
1139,
55,
559,
3456,
1026,
16,
509,
1203,
13,
288,
3639,
368,
309,
10379,
353,
1281,
5784,
559,
16,
1508,
518,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5784,
12041,
8482,
8809,
12,
20228,
5126,
10379,
16,
1139,
55,
559,
3456,
1026,
16,
509,
1203,
13,
288,
3639,
368,
309,
10379,
353,
1281,
5784,
559,
16,
1508,
518,
... |
if ( seriesList == null ) { seriesList = ( (Axis) axisList.get( i ) ).getSeriesDefinitions( ); } else { seriesList.addAll( ( (Axis) axisList.get( i ) ).getSeriesDefinitions( ) ); } | seriesList.addAll( ( (Axis) axisList.get( i ) ).getSeriesDefinitions( ) ); | public static EList getOrthogonalSeriesDefinitions( Chart chart, int axisIndex ) { if ( chart instanceof ChartWithAxes ) { EList axisList = ( (Axis) ( (ChartWithAxes) chart ).getAxes( ) .get( 0 ) ).getAssociatedAxes( ); if ( axisIndex >= 0 ) { return ( (Axis) axisList.get( axisIndex ) ).getSeriesDefinitions( ); } EList seriesList = null; for ( int i = 0; i < axisList.size( ); i++ ) { if ( seriesList == null ) { seriesList = ( (Axis) axisList.get( i ) ).getSeriesDefinitions( ); } else { seriesList.addAll( ( (Axis) axisList.get( i ) ).getSeriesDefinitions( ) ); } } return seriesList; } else if ( chart instanceof ChartWithoutAxes ) { return ( (SeriesDefinition) ( (ChartWithoutAxes) chart ).getSeriesDefinitions( ) .get( 0 ) ).getSeriesDefinitions( ); } return null; } | 46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/9a0ef16578ddeb2a6605fff7bacaef57b465350a/ChartUIUtil.java/clean/chart/org.eclipse.birt.chart.ui/src/org/eclipse/birt/chart/ui/util/ChartUIUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
17021,
10117,
451,
28396,
6485,
7130,
12,
14804,
4980,
16,
1082,
202,
474,
2654,
1016,
262,
202,
95,
202,
202,
430,
261,
4980,
1276,
14804,
1190,
26494,
262,
202,
202,
95,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
17021,
10117,
451,
28396,
6485,
7130,
12,
14804,
4980,
16,
1082,
202,
474,
2654,
1016,
262,
202,
95,
202,
202,
430,
261,
4980,
1276,
14804,
1190,
26494,
262,
202,
202,
95,
... |
MarkerFilter[] getEnabledFilters(){ if(enabledFilters == null){ MarkerFilter[] allFilters = getFilters(); ArrayList filters = new ArrayList(0); for (int i = 0; i < allFilters.length; i++) { if(allFilters[i].isEnabled()) filters.add(allFilters[i]); } enabledFilters = new MarkerFilter[filters.size()]; filters.toArray(enabledFilters); } return enabledFilters; } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/09a4c864bb83fb62a685d497a2df9ce5451376bd/MarkerView.java/buggy/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/MarkerView.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
7078,
1586,
8526,
336,
1526,
5422,
1435,
95,
9506,
202,
430,
12,
5745,
5422,
422,
446,
15329,
1082,
202,
7078,
1586,
8526,
777,
5422,
273,
25175,
5621,
1082,
202,
19558,
3415,
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,
7078,
1586,
8526,
336,
1526,
5422,
1435,
95,
9506,
202,
430,
12,
5745,
5422,
422,
446,
15329,
1082,
202,
7078,
1586,
8526,
777,
5422,
273,
25175,
5621,
1082,
202,
19558,
3415,
273,
3... | ||
if (start < 0) start = 0; if (end > tlen) end = tlen; if (end < 0 || start >= end) return null; if (fLength == 0) return new Position(start, start); | if (start < 0) { start = 0; } if (end > tlen) { end = tlen; } if (end < 0 || start >= end) { return null; } if (fLength == 0) { return new Position(start, start); } | public StringMatcher.Position find(String text, int start, int end) { if (text == null) throw new IllegalArgumentException(); int tlen = text.length(); if (start < 0) start = 0; if (end > tlen) end = tlen; if (end < 0 || start >= end) return null; if (fLength == 0) return new Position(start, start); if (fIgnoreWildCards) { int x = posIn(text, start, end); if (x < 0) return null; return new Position(x, x + fLength); } int segCount = fSegments.length; if (segCount == 0)//pattern contains only '*'(s) return new Position(start, end); int curPos = start; int matchStart = -1; int i; for (i = 0; i < segCount && curPos < end; ++i) { String current = fSegments[i]; int nextMatch = regExpPosIn(text, curPos, end, current); if (nextMatch < 0) return null; if (i == 0) matchStart = nextMatch; curPos = nextMatch + current.length(); } if (i < segCount) // Ensure all segments match return null; return new Position(matchStart, curPos); } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/e38d295ea613cf9f08aadb93a84a33d2e91abc5f/StringMatcher.java/clean/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/navigator/StringMatcher.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
6286,
18,
2555,
1104,
12,
780,
977,
16,
509,
787,
16,
509,
679,
13,
288,
3639,
309,
261,
955,
422,
446,
13,
5411,
604,
394,
2754,
5621,
3639,
509,
268,
1897,
273,
977,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
6286,
18,
2555,
1104,
12,
780,
977,
16,
509,
787,
16,
509,
679,
13,
288,
3639,
309,
261,
955,
422,
446,
13,
5411,
604,
394,
2754,
5621,
3639,
509,
268,
1897,
273,
977,
18,
... |
d.print("</tr>\n"); | d.print("</tr>"); | public void write(Device d, SLayoutManager l) throws IOException { SBorderLayout layout = (SBorderLayout) l; SComponent north = (SComponent) layout.getComponents().get(SBorderLayout.NORTH); SComponent east = (SComponent) layout.getComponents().get(SBorderLayout.EAST); SComponent center = (SComponent) layout.getComponents().get(SBorderLayout.CENTER); SComponent west = (SComponent) layout.getComponents().get(SBorderLayout.WEST); SComponent south = (SComponent) layout.getComponents().get(SBorderLayout.SOUTH); int cols = 0; if (west != null) cols++; if (center != null) cols++; if (east != null) cols++; d.print("\n<table class=\"SBorderLayout\" cellpadding=\"0\" cellspacing=\"0\"><tbody>"); if (north != null) { d.print("\n<tr style=\"height: 0%\"><td colspan=\"").print(cols).print("\">"); writeComponent(d, north); d.print("</td></tr>"); } d.print("\n<tr style=\"height: 100%\">"); if (west != null) { d.print("<td style=\"width: 0%\">"); writeComponent(d, west); d.print("</td>"); } if (center != null) { d.print("<td style=\"width: 100%\">"); writeComponent(d, center); d.print("</td>"); } if (east != null) { d.print("<td style=\"width: 0%\">"); writeComponent(d, east); d.print("</td>"); } d.print("</tr>\n"); if (south != null) { d.print("\n<tr style=\"height: 0%\"><td colspan=\"").print(cols).print("\">"); writeComponent(d, south); d.print("</td></tr>"); } d.print("\n</tbody></table>"); } | 3911 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3911/a13e1e051952689f51f8e2bee7381d6e03645ee4/BorderLayoutCG.java/buggy/wings2/src/java/org/wings/plaf/css/BorderLayoutCG.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1045,
12,
3654,
302,
16,
348,
3744,
1318,
328,
13,
5411,
1216,
1860,
288,
3639,
348,
8107,
3744,
3511,
273,
261,
55,
8107,
3744,
13,
328,
31,
3639,
348,
1841,
21435,
273,
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,
918,
1045,
12,
3654,
302,
16,
348,
3744,
1318,
328,
13,
5411,
1216,
1860,
288,
3639,
348,
8107,
3744,
3511,
273,
261,
55,
8107,
3744,
13,
328,
31,
3639,
348,
1841,
21435,
273,
261... |
public org.quickfix.field.SettlCurrency getSettlCurrency() throws FieldNotFound { org.quickfix.field.SettlCurrency value = new org.quickfix.field.SettlCurrency(); | public quickfix.field.SettlCurrency getSettlCurrency() throws FieldNotFound { quickfix.field.SettlCurrency value = new quickfix.field.SettlCurrency(); | public org.quickfix.field.SettlCurrency getSettlCurrency() throws FieldNotFound { org.quickfix.field.SettlCurrency value = new org.quickfix.field.SettlCurrency(); getField(value); return value; } | 8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/Allocation.java/clean/src/java/src/quickfix/fix40/Allocation.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
694,
6172,
7623,
336,
694,
6172,
7623,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
694,
6172,
7623,
460,
273,
394,
23... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
694,
6172,
7623,
336,
694,
6172,
7623,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
694,
6172,
7623,
460,
273,
394,
23... |
Scriptable scope, int type) | Scriptable scope, int incrDecrMask) | public static Object elemIncrDecr(Object obj, Object index, Scriptable scope, int type) { Object value = getElem(obj, index, scope); if (value == Undefined.instance) return value; boolean post = (type == Node.POST_INC || type == Node.POST_DEC); double number; if (value instanceof Number) { number = ((Number)value).doubleValue(); } else { number = toNumber(value); if (post) { // convert result to number value = new Double(number); } } if (type == Node.PRE_INC || type == Node.POST_INC) { ++number; } else { --number; } Number result = new Double(number); setElem(obj, index, result, scope); if (post) { return value; } else { return result; } } | 13991 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13991/cb3a4fef51dd031baf4bc78bcf8cc452587ea3b7/ScriptRuntime.java/clean/js/rhino/src/org/mozilla/javascript/ScriptRuntime.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1033,
3659,
382,
3353,
1799,
86,
12,
921,
1081,
16,
1033,
770,
16,
4766,
1377,
22780,
2146,
16,
509,
17633,
1799,
86,
5796,
13,
565,
288,
3639,
1033,
460,
273,
4774,
3269,
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,
1033,
3659,
382,
3353,
1799,
86,
12,
921,
1081,
16,
1033,
770,
16,
4766,
1377,
22780,
2146,
16,
509,
17633,
1799,
86,
5796,
13,
565,
288,
3639,
1033,
460,
273,
4774,
3269,
12... |
} else if (child.getElementType() == ElementType.XML_END_TAG_START) { | } else if (child.getElementType() == ElementType.XML_START_TAG_START) { insideTag = false; child = processChild(localResult,child, wrap, alignment, null); } else if (child.getElementType() == ElementType.XML_END_TAG_START) { | protected List<Block> buildChildren() { ChameleonTransforming.transformChildren(myNode); ASTNode child = myNode.getFirstChildNode(); final Formatter formatter = getFormatter(); final Wrap attrWrap = formatter.createWrap(getWrapType(myXmlFormattingPolicy.getAttributesWrap()), false); final Wrap textWrap = formatter.createWrap(getWrapType(myXmlFormattingPolicy.getTextWrap()), true); final Wrap tagBeginWrap = createTagBeginWrapping(getTag()); final Alignment attrAlignment = formatter.createAlignment(); final Alignment textAlignment = formatter.createAlignment(); final ArrayList<Block> result = new ArrayList<Block>(); ArrayList<Block> localResult = new ArrayList<Block>(); boolean insideTag = false; while (child != null) { if (!FormatterUtil.containsWhiteSpacesOnly(child) && child.getTextLength() > 0){ Wrap wrap = chooseWrap(child, tagBeginWrap, attrWrap, textWrap); Alignment alignment = chooseAlignment(child, attrAlignment, textAlignment); if (child.getElementType() == ElementType.XML_TAG_END) { child = processChild(localResult,child, wrap, alignment, null); result.add(createTagDescriptionNode(localResult)); localResult = new ArrayList<Block>(); insideTag = true; } else if (child.getElementType() == ElementType.XML_END_TAG_START) { insideTag = false; if (!localResult.isEmpty()) { result.add(createTagContentNode(localResult)); localResult = new ArrayList<Block>(); } child = processChild(localResult,child, wrap, alignment, null); } else if (child.getElementType() == ElementType.XML_EMPTY_ELEMENT_END) { child = processChild(localResult,child, wrap, alignment, null); result.add(createTagDescriptionNode(localResult)); localResult = new ArrayList<Block>(); } else if (isJspxJavaContainingNode(child)) { child = createJspTextNode(localResult, child, getChildIndent()); } else if (child.getElementType() == ElementType.XML_TEXT) { child = createXmlTextBlocks(localResult, child, wrap, alignment); } else { final Indent indent; if (localResult.size() == 1 && localResult.get(0) instanceof JspTextBlock) { //indent = Formatter.getInstance().getNoneIndent(); indent = myXmlFormattingPolicy.indentChildrenOf(getTag()) ? getFormatter().createNormalIndent() : getFormatter().getNoneIndent(); } else if (!insideTag) { indent = null; } else { indent = myXmlFormattingPolicy.indentChildrenOf(getTag()) ? getFormatter().createNormalIndent() : getFormatter().getNoneIndent(); } child = processChild(localResult,child, wrap, alignment, indent); } } if (child != null) { child = child.getTreeNext(); } } if (!localResult.isEmpty()) { result.add(createTagContentNode(localResult)); } return result; } | 17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/3b85fe28c93f37278939c8d6fb7041de30874798/XmlTagBlock.java/clean/source/com/intellij/psi/formatter/xml/XmlTagBlock.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
4750,
987,
32,
1768,
34,
1361,
4212,
1435,
288,
565,
1680,
301,
6516,
265,
4059,
310,
18,
6547,
4212,
12,
4811,
907,
1769,
565,
9183,
907,
1151,
273,
3399,
907,
18,
588,
3759,
25550,
56... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
987,
32,
1768,
34,
1361,
4212,
1435,
288,
565,
1680,
301,
6516,
265,
4059,
310,
18,
6547,
4212,
12,
4811,
907,
1769,
565,
9183,
907,
1151,
273,
3399,
907,
18,
588,
3759,
25550,
56... |
LCount lc = LCount.lookup(MutationEventImpl.DOM_CHARACTER_DATA_MODIFIED); if (lc.captures + lc.bubbles + lc.defaults > 0) { MutationEvent me = new MutationEventImpl(); me.initMutationEvent( MutationEventImpl.DOM_CHARACTER_DATA_MODIFIED, true, false, null, oldvalue, value, null, (short) 0); dispatchEvent(node, me); } | if (!replace) { LCount lc = LCount.lookup(MutationEventImpl.DOM_CHARACTER_DATA_MODIFIED); if (lc.total > 0) { MutationEvent me = new MutationEventImpl(); me.initMutationEvent( MutationEventImpl.DOM_CHARACTER_DATA_MODIFIED, true, false, null, oldvalue, value, null, (short) 0); dispatchEvent(node, me); } | void modifiedCharacterData(NodeImpl node, String oldvalue, String value) { if (mutationEvents) { // MUTATION POST-EVENTS: LCount lc = LCount.lookup(MutationEventImpl.DOM_CHARACTER_DATA_MODIFIED); if (lc.captures + lc.bubbles + lc.defaults > 0) { MutationEvent me = new MutationEventImpl(); me.initMutationEvent( MutationEventImpl.DOM_CHARACTER_DATA_MODIFIED, true, false, null, oldvalue, value, null, (short) 0); dispatchEvent(node, me); } // Subroutine: Transmit DOMAttrModified and DOMSubtreeModified, // if required. (Common to most kinds of mutation) dispatchAggregateEvents(node, savedEnclosingAttr); } // End mutation postprocessing } | 4434 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4434/b98b83060e13672ad49242ff55cfecac2d8533bd/DocumentImpl.java/clean/src/org/apache/xerces/dom/DocumentImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
4358,
7069,
751,
12,
907,
2828,
756,
16,
514,
1592,
1132,
16,
514,
460,
13,
288,
3639,
309,
261,
28868,
3783,
13,
288,
5411,
368,
490,
1693,
2689,
5485,
17,
29221,
30,
5411,
511,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
4358,
7069,
751,
12,
907,
2828,
756,
16,
514,
1592,
1132,
16,
514,
460,
13,
288,
3639,
309,
261,
28868,
3783,
13,
288,
5411,
368,
490,
1693,
2689,
5485,
17,
29221,
30,
5411,
511,
... |
URL helloworld = Platform.asLocalURL(Platform.find(TestPlugin.getDefault().getBundle(), new Path(PATH_PREFIX+"HelloWorld"))); | String dataLocation = copyDataLocation(); IPath wsPath = new Path(dataLocation).append(PLUGIN_ID).append( DATA_PATH_PREFIX).append("HelloWorld"); | public void testFindSingleDirectory() { try { URL helloworld = Platform.asLocalURL(Platform.find(TestPlugin.getDefault().getBundle(), new Path(PATH_PREFIX+"HelloWorld"))); WizardProjectsImportPage wpip = getNewWizard(); HashSet projects = new HashSet(); projects.add("HelloWorld"); wpip.getProjectFromDirectoryRadio().setSelection((true)); // We're importing a directory wpip.updateProjectsList(helloworld.getPath()); ProjectRecord[] selectedProjects= wpip.getProjects(); ArrayList projectNames = new ArrayList(); for (int i = 0; i < selectedProjects.length; i++) { projectNames.add(selectedProjects[i].getProjectName()); } assertTrue("Not all projects were found correctly in directory", projectNames.containsAll(projects)); } catch (IOException e) { fail(e.toString()); } } | 56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/b3aa3b90e0dc729086b2402e3b4024f5c167451d/ImportExistingTest.java/clean/tests/org.eclipse.ui.tests/Eclipse UI Tests/org/eclipse/ui/tests/datatransfer/ImportExistingTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
3125,
5281,
2853,
1435,
288,
202,
202,
698,
288,
1082,
202,
1785,
366,
11394,
6245,
273,
11810,
18,
345,
2042,
1785,
12,
8201,
18,
4720,
12,
4709,
3773,
18,
588,
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,
3125,
5281,
2853,
1435,
288,
202,
202,
698,
288,
1082,
202,
1785,
366,
11394,
6245,
273,
11810,
18,
345,
2042,
1785,
12,
8201,
18,
4720,
12,
4709,
3773,
18,
588,
18... |
if(pathToTokens == null || pathToTokens.isEmpty()){ return; } Set keySet = pathToTokens.keySet(); Iterator keyPathIter = keySet.iterator(); while(keyPathIter.hasNext()){ String keyPath = (String)keyPathIter.next(); String tokenVal = (String)pathToTokens.get(keyPath); FSWriter.doUnlock(keyPath, tokenVal, getUserName(), force, myReposRootDir); | try{ openRepository(); for (Iterator paths = pathToTokens.keySet().iterator(); paths.hasNext();) { String path = (String)paths.next(); String token = (String)pathToTokens.get(path); String reposPath = getRepositoryPath(path); SVNErrorMessage error = null; try{ FSWriter.unlockPath(reposPath, token, getUserName(), force, myReposRootDir); }catch(SVNException svne){ error = svne.getErrorMessage(); if(!FSErrors.isUnlockError(error)){ throw svne; } } if(handler != null){ handler.handleUnlock(reposPath, new SVNLock(reposPath, token, null, null, null, null), error); } } }finally{ closeRepository(); | public void unlock(Map pathToTokens, boolean force, ISVNLockHandler handler) throws SVNException { if(pathToTokens == null || pathToTokens.isEmpty()){ return; } Set keySet = pathToTokens.keySet(); Iterator keyPathIter = keySet.iterator(); while(keyPathIter.hasNext()){ String keyPath = (String)keyPathIter.next(); String tokenVal = (String)pathToTokens.get(keyPath); FSWriter.doUnlock(keyPath, tokenVal, getUserName(), force, myReposRootDir); } } | 2776 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2776/b3f8504a7a88adac90f7f3c9205942041f95e328/FSRepository.java/clean/javasvn/src/org/tmatesoft/svn/core/internal/io/fs/FSRepository.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
7186,
12,
863,
12221,
5157,
16,
1250,
2944,
16,
4437,
58,
50,
2531,
1503,
1838,
13,
1216,
29537,
50,
503,
288,
3639,
309,
12,
803,
774,
5157,
422,
446,
747,
12221,
5157,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
7186,
12,
863,
12221,
5157,
16,
1250,
2944,
16,
4437,
58,
50,
2531,
1503,
1838,
13,
1216,
29537,
50,
503,
288,
3639,
309,
12,
803,
774,
5157,
422,
446,
747,
12221,
5157,
18,
... |
} | public TextEdit getJspEdit(TextEdit javaEdit) { List jspEdits = new ArrayList(); int offset = javaEdit.getOffset(); int length = javaEdit.getLength(); if(javaEdit instanceof MultiTextEdit && javaEdit.getChildren().length > 0) { IRegion r = TextEdit.getCoverage(getAllEdits(javaEdit)); offset = r.getOffset(); length = r.getLength(); } // get java ranges that will be affected by the edit Position[] javaPositions = getJavaRanges(offset, length); // record position data before the change Position[] jspPositions = new Position[javaPositions.length]; PositionDelta[] deltas = new PositionDelta[javaPositions.length]; for(int i=0; i<javaPositions.length; i++) { deltas[i] = new PositionDelta(javaPositions[i].offset, javaPositions[i].length); // isIndirect means the position doesn't actually exist as exact text // mapping from java <-> jsp (eg. an import statement) if(!isIndirect(javaPositions[i].offset)) jspPositions[i] = (Position)getJava2JspMap().get(javaPositions[i]); } if(DEBUG) { System.out.println("================================================"); System.out.println("deltas:"); String javaText = getJavaText(); for(int i=0; i<deltas.length; i++) System.out.println("pos[" + deltas[i].preOffset + ":" + deltas[i].preLength + "]" + javaText.substring(deltas[i].preOffset, deltas[i].preOffset + deltas[i].preLength) ); System.out.println("==============================================="); } // apply the edit to the java document try { javaEdit.apply(getJavaDocument()); } catch (MalformedTreeException e) { Logger.logException(e); } catch (BadLocationException e) { Logger.logException(e); } // now at this point Java positions are unreliable since they were updated after applying java edit. String newJavaText = getJavaDocument().get(); if(DEBUG) System.out.println("java post format text:\n" + newJavaText); //$NON-NLS-1$ // record post edit data for(int i=0; i<javaPositions.length; i++) deltas[i].setPostEditData(javaPositions[i].offset, javaPositions[i].length, javaPositions[i].isDeleted); // create appropriate text edits for deltas Position jspPos = null; String replaceText = ""; //$NON-NLS-1$ for(int i=0; i<deltas.length; i++) { jspPos = jspPositions[i]; // can be null if it's an indirect mapping position // or if something was added into java that was not originally in JSP (like a new import...) if(jspPos != null) { if(deltas[i].isDeleted) { jspEdits.add(new DeleteEdit(jspPos.offset, jspPos.length)); } else { replaceText = newJavaText.substring(deltas[i].postOffset, deltas[i].postOffset + deltas[i].postLength); jspEdits.add(new ReplaceEdit(jspPos.offset, jspPos.length, replaceText)); } if(DEBUG) debugReplace(deltas, jspPos, replaceText, i); } else { // the new Java text has no corresponding JSP position // possible new import? if(isImport(javaPositions[i].getOffset()) && replaceText.lastIndexOf("import ") != -1) { //$NON-NLS-1$ replaceText = newJavaText.substring(deltas[i].postOffset, deltas[i].postOffset + deltas[i].postLength); String importText = replaceText.substring(replaceText.lastIndexOf("import "), replaceText.indexOf(";")); //$NON-NLS-1$ //$NON-NLS-2$ // evenutally need to check if it's XML-JSP importText = "<%@page import=\"" + importText + "\" %>\n"; //$NON-NLS-1$ //$NON-NLS-2$ jspEdits.add(new InsertEdit(0, importText)); } } } return createMultiTextEdit((TextEdit[])jspEdits.toArray(new TextEdit[jspEdits.size()])); } | 13989 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13989/2e01915a5c78fe7220591d5dfc6ebf923eaed5f2/JSPTranslationExtension.java/buggy/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/java/JSPTranslationExtension.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
3867,
4666,
31162,
4666,
12,
1528,
4666,
2252,
4666,
13,
288,
202,
202,
682,
22535,
2671,
1282,
273,
394,
2407,
5621,
202,
202,
474,
1384,
273,
2252,
4666,
18,
588,
2335,
5621,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
3867,
4666,
31162,
4666,
12,
1528,
4666,
2252,
4666,
13,
288,
202,
202,
682,
22535,
2671,
1282,
273,
394,
2407,
5621,
202,
202,
474,
1384,
273,
2252,
4666,
18,
588,
2335,
5621,
... | |
return "TCP"; } | return "TCP"; } | public String getTransport() { return "TCP"; } | 3364 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3364/68c0ca844a7d5fe4a7744cbf9898184966ce0680/TCPMessageChannel.java/buggy/src/gov/nist/javax/sip/stack/TCPMessageChannel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
29801,
1435,
288,
3639,
327,
315,
13891,
14432,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
29801,
1435,
288,
3639,
327,
315,
13891,
14432,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
this.isInPaintMethod = true; | public final void paint(Graphics g) { //#if tmp.fullScreenInPaint if (!this.isInFullScreenMode) { super.setFullScreenMode( true ); this.isInFullScreenMode = true; //#ifdef polish.FullCanvasHeight:defined //#= this.fullScreenHeight = ${polish.FullCanvasHeight}; //#else this.fullScreenHeight = getHeight(); //#endif this.screenHeight = this.fullScreenHeight - this.menuBarHeight; this.originalScreenHeight = this.screenHeight; this.scrollIndicatorY = this.screenHeight - this.scrollIndicatorWidth - 1; } //#endif //#if polish.useFullScreen && polish.api.nokia-ui this.isInPaintMethod = true; //#endif //#ifdef polish.debug.error try { //#endif // paint background: if (this.background != null) { //#ifdef tmp.menuFullScreen this.background.paint(0, 0, this.screenWidth, this.fullScreenHeight, g); //#else this.background.paint(0, 0, this.screenWidth, this.screenHeight, g); //#endif } else { g.setColor( 0xFFFFFF ); //#ifdef tmp.menuFullScreen g.fillRect( 0, 0, this.screenWidth, this.fullScreenHeight ); //#else g.fillRect( 0, 0, this.screenWidth, this.screenHeight ); //#endif } int tHeight = 0; //#ifdef tmp.usingTitle // paint title: if (this.title != null && this.showTitleOrMenu) { this.title.paint(0, 0, 0, this.screenWidth, g); tHeight = this.titleHeight; } //#elif !tmp.menuFullScreen int translateY = g.getTranslateY(); if (translateY != 0 && this.screenHeight == this.originalScreenHeight) { this.screenHeight -= translateY; this.scrollIndicatorY -= translateY; //#debug System.out.println("Adjusting screenheight from " + this.originalScreenHeight + " to " + this.screenHeight ); if (this.container != null) { this.container.setVerticalDimensions(translateY, this.screenHeight); } } //#endif if (this.subTitle != null) { this.subTitle.paint( 0, tHeight, 0, this.screenWidth, g ); tHeight += this.subTitleHeight; } if (this.showInfoItem) { this.infoItem.paint( 0, tHeight, 0, this.screenWidth, g ); tHeight += this.infoHeight; } // protect the title, ticker and the full-screen-menu area: g.setClip(0, tHeight, this.screenWidth, this.screenHeight - tHeight ); g.translate( 0, tHeight ); // paint content: //System.out.println("starting to paint content of screen"); paintScreen( g ); //System.out.println("done painting content of screen"); g.translate( 0, - tHeight ); // allow painting outside of the screen again: //#ifdef tmp.menuFullScreen g.setClip(0, 0, this.screenWidth, this.fullScreenHeight ); //#else g.setClip(0, 0, this.screenWidth, this.originalScreenHeight ); //#endif //#ifndef polish.skipTicker if (this.ticker != null) { this.ticker.paint( 0, this.screenHeight, 0, this.screenWidth, g ); } //#endif // paint border: if (this.border != null) { this.border.paint(0, 0, this.screenWidth, this.screenHeight, g); } // paint menu in full-screen mode: //#ifdef tmp.menuFullScreen //#ifdef tmp.useExternalMenuBar this.menuBar.paint(0, this.screenHeight, 0, this.screenWidth, g); if (this.menuBar.isOpened) { this.paintScrollIndicator = this.menuBar.paintScrollIndicator; this.paintScrollIndicatorUp = this.menuBar.canScrollUpwards; this.paintScrollIndicatorDown = this.menuBar.canScrollDownwards; } //#else if (this.menuOpened) { tHeight -= this.infoHeight; int menuHeight = this.menuContainer.getItemHeight(this.menuMaxWidth, this.menuMaxWidth); int y = this.originalScreenHeight - menuHeight; if (y < tHeight) { this.paintScrollIndicator = true; this.paintScrollIndicatorUp = (this.menuContainer.yOffset != 0); this.paintScrollIndicatorDown = (this.menuContainer.yOffset + menuHeight > this.originalScreenHeight - tHeight); y = tHeight; this.menuContainer.setVerticalDimensions(y, this.originalScreenHeight); } else { this.paintScrollIndicator = false; } g.setClip(0, tHeight, this.screenWidth, this.originalScreenHeight - tHeight ); this.menuContainer.paint(0, y, 0, this.menuMaxWidth, g); g.setClip(0, 0, this.screenWidth, this.fullScreenHeight ); } if (this.showTitleOrMenu || this.menuOpened) { // clear menu-bar: if (this.menuBarColor != Item.TRANSPARENT) { g.setColor( this.menuBarColor ); g.fillRect(0, this.originalScreenHeight, this.screenWidth, this.menuBarHeight ); } if (this.menuContainer != null && this.menuContainer.size() > 0) { String menuText = null; if (this.menuOpened) { //#ifdef polish.command.select:defined //#= menuText = "${polish.command.select}"; //#else menuText = "Select"; //#endif } else { if (this.menuSingleLeftCommand != null) { menuText = this.menuSingleLeftCommand.getLabel(); } else { //#ifdef polish.command.options:defined //#= menuText = "${polish.command.options}"; //#else menuText = "Options"; //#endif } } //#ifdef polish.hasPointerEvents this.menuLeftCommandX = 2 + this.menuFont.stringWidth( menuText ); //#endif g.setColor( this.menuFontColor ); g.setFont( this.menuFont ); //#ifdef polish.Menu.MarginLeft:defined //#= int menuX = ${polish.Menu.MarginLeft}; //#else int menuX = 2; //#endif //#ifdef polish.Menu.MarginTop:defined //#= g.drawString(menuText, menuX, this.originalScreenHeight + ${polish.Menu.MarginTop}, Graphics.TOP | Graphics.LEFT ); //#else g.drawString(menuText, menuX, this.originalScreenHeight + 2, Graphics.TOP | Graphics.LEFT ); //#endif if ( this.menuOpened ) { // draw cancel string: //#ifdef polish.command.cancel:defined //#= menuText = "${polish.command.cancel}"; //#else menuText = "Cancel"; //#endif //#ifdef polish.Menu.MarginRight:defined //#= menuX = ${polish.Menu.MarginRight}; //#elifdef polish.Menu.MarginLeft:defined menuX = 2; //#endif //#ifdef polish.Menu.MarginTop:defined //#= g.drawString(menuText, this.screenWidth - menuX, this.originalScreenHeight + ${polish.Menu.MarginTop}, Graphics.TOP | Graphics.RIGHT ); //#else g.drawString(menuText, this.screenWidth - menuX, this.originalScreenHeight + 2, Graphics.TOP | Graphics.RIGHT ); //#endif //#ifdef polish.hasPointerEvents this.menuRightCommandX = this.screenWidth - 2 - this.menuFont.stringWidth( menuText ); //#endif } } if (this.menuSingleRightCommand != null && !this.menuOpened) { g.setColor( this.menuFontColor ); g.setFont( this.menuFont ); String menuText = this.menuSingleRightCommand.getLabel(); //#ifdef polish.Menu.MarginRight:defined //#= int menuX = ${polish.Menu.MarginRight}; //#else int menuX = 2; //#endif //#ifdef polish.Menu.MarginTop:defined //#= g.drawString(menuText, this.screenWidth - menuX, this.originalScreenHeight + ${polish.Menu.MarginTop}, Graphics.TOP | Graphics.RIGHT ); //#else g.drawString(menuText, this.screenWidth - menuX, this.originalScreenHeight + 2, Graphics.TOP | Graphics.RIGHT ); //#endif //#ifdef polish.hasPointerEvents this.menuRightCommandX = this.screenWidth - menuX - this.menuFont.stringWidth( menuText ); //#endif } } // if this.showTitleOrMenu || this.menuOpened //#endif //#endif // paint scroll-indicator in the middle of the menu: if (this.paintScrollIndicator) { g.setColor( this.scrollIndicatorColor ); int x = this.scrollIndicatorX; int y = this.scrollIndicatorY; int width = this.scrollIndicatorWidth; int halfWidth = width / 2; if (this.paintScrollIndicatorUp) { //#ifdef polish.midp2 g.fillTriangle(x, y + halfWidth-1, x + width, y + halfWidth-1, x + halfWidth, y ); //#else g.drawLine( x, y + halfWidth-1, x + width, y + halfWidth-1 ); g.drawLine( x, y + halfWidth-1, x + halfWidth, y ); g.drawLine( x + width, y + halfWidth-1, x + halfWidth, y ); //#endif } if (this.paintScrollIndicatorDown) { //#ifdef polish.midp2 g.fillTriangle(x, y + halfWidth+1, x + width, y + halfWidth+1, x + halfWidth, y + width ); //#else g.drawLine( x, y + halfWidth+1, x + width, y + halfWidth+1 ); g.drawLine( x, y + halfWidth+1, x + halfWidth, y + width ); g.drawLine(x + width, y + halfWidth+1, x + halfWidth, y + width ); //#endif } } //#ifdef polish.css.foreground-image if (this.foregroundImage != null) { g.drawImage( this.foregroundImage, this.foregroundX, this.foregroundY, Graphics.TOP | Graphics.LEFT ); } //#endif //#ifdef polish.debug.error } catch (RuntimeException e) { //#debug error Debug.debug( "unable to paint screen", e ); } //#endif //#if polish.useFullScreen && polish.api.nokia-ui this.lastPaintTime = System.currentTimeMillis(); this.isInPaintMethod = false; //#endif } | 9804 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9804/2d2ee1a8b2dd39fe6c831aded2568d110a1ee975/Screen.java/buggy/j2me/source/src/de/enough/polish/ui/Screen.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
12574,
12,
17558,
314,
13,
288,
202,
202,
759,
7,
430,
1853,
18,
2854,
7956,
382,
12699,
1082,
202,
430,
16051,
2211,
18,
291,
382,
5080,
7956,
2309,
13,
288,
9506,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
12574,
12,
17558,
314,
13,
288,
202,
202,
759,
7,
430,
1853,
18,
2854,
7956,
382,
12699,
1082,
202,
430,
16051,
2211,
18,
291,
382,
5080,
7956,
2309,
13,
288,
9506,
... | |
EPerson sub ) | EPerson sub) | public static WorkspaceItem create(Context context, Collection coll, EPerson sub ) throws AuthorizeException, SQLException { // FIXME Check authorisation // Create an item Item i = Item.create(context); i.setSubmitter(sub); // Create the personal workspace row TableRow row = DatabaseManager.create(context, "personalworkspace"); row.setColumn("item_id", i.getID()); row.setColumn("collection_id", coll.getID()); return new WorkspaceItem(context, row); } | 1868 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1868/85c7430ba7691f831fafc420459d280408310eb9/WorkspaceItem.java/clean/dspace/src/org/dspace/content/WorkspaceItem.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
14396,
1180,
752,
12,
1042,
819,
16,
4766,
4202,
2200,
4508,
16,
4766,
4202,
512,
8346,
720,
13,
3639,
1216,
23859,
503,
16,
6483,
565,
288,
3639,
368,
9852,
2073,
2869,
10742,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
14396,
1180,
752,
12,
1042,
819,
16,
4766,
4202,
2200,
4508,
16,
4766,
4202,
512,
8346,
720,
13,
3639,
1216,
23859,
503,
16,
6483,
565,
288,
3639,
368,
9852,
2073,
2869,
10742,... |
/* if (type == T_CHAR && c == '^') { this.next(); type = this.read(); c = this.chardata; if (type == T_EOF) break; nrange = !nrange; if (nrange) tok = Token.createRange(); else { base.subtractRanges(tok); tok = base; } } */ | private RangeToken parseCharacterClass(boolean useNrange) throws ParseException { this.setContext(S_INBRACKETS); this.next(); // '[' boolean nrange = false; RangeToken base = null; RangeToken tok; if (this.read() == T_CHAR && this.chardata == '^') { nrange = true; this.next(); // '^' if (useNrange) { tok = Token.createNRange(); } else { base = Token.createRange(); base.addRange(0, 0xffff); tok = Token.createRange(); } } else { tok = Token.createRange(); } int type; while ((type = this.read()) != T_EOF && !(type == T_CHAR && this.chardata == ']')) { int c = this.chardata; /* if (type == T_CHAR && c == '^') { this.next(); type = this.read(); c = this.chardata; if (type == T_EOF) break; nrange = !nrange; if (nrange) tok = Token.createRange(); else { base.subtractRanges(tok); tok = base; } } */ boolean end = false; if (type == T_BACKSOLIDUS) { switch (c) { case 'd': case 'D': case 'w': case 'W': case 's': case 'S': tok.mergeRanges(this.getTokenForShorthand(c)); end = true; break; case 'i': case 'I': case 'c': case 'C': c = this.processCIinCharacterClass(tok, c); if (c < 0) end = true; break; case 'p': case 'P': boolean positive = c == 'p'; int pstart = this.offset; this.next(); if (this.read() != T_CHAR) throw ex("parser.atom.2", this.offset-1); RangeToken tok2 = null; switch (this.chardata) { case 'L': // Letter tok2 = Token.getRange("L", positive); break; case 'M': // Mark tok2 = Token.getRange("M", positive); break; case 'N': // Number tok2 = Token.getRange("N", positive); break; case 'Z': // Separator tok2 = Token.getRange("Z", positive); break; case 'C': // Other tok2 = Token.getRange("C", positive); break; case 'P': // Punctuation tok2 = Token.getRange("P", positive); break; case 'S': // Symbol tok2 = Token.getRange("S", positive); break; case '{': // this.offset points the next of '{'. pstart = this.offset; int namestart = this.offset; int nameend = this.regex.indexOf('}', namestart); if (nameend < 0) throw ex("parser.atom.3", this.offset); this.offset = nameend+1; tok2 = Token.getRange(this.regex.substring(namestart, nameend), positive); break; default: throw ex("parser.atom.2", this.offset-1); } if (tok2 == null) throw ex("parser.atom.5", pstart); tok.mergeRanges(tok2); end = true; break; default: c = this.decodeEscaped(); } // \ + c } // backsolidus // POSIX Character class such as [:alnum:] else if (type == T_POSIX_CHARCLASS_START) { int nameend = this.regex.indexOf(':', this.offset); if (nameend < 0) throw ex("parser.cc.1", this.offset); String name = this.regex.substring(this.offset, nameend); RangeToken range = Token.getRange(name, true); if (range == null) throw ex("parser.cc.3", this.offset); tok.mergeRanges(range); end = true; if (nameend+1 >= this.regexlen || this.regex.charAt(nameend+1) != ']') throw ex("parser.cc.1", nameend); this.offset = nameend+2; } this.next(); if (!end) { if (this.read() != T_CHAR || this.chardata != '-') { // Here is no '-'. tok.addRange(c, c); } else { this.next(); // Skips '-' if ((type = this.read()) == T_EOF) throw ex("parser.cc.2", this.offset); int rangeend = this.chardata; if (type == T_BACKSOLIDUS) rangeend = this.decodeEscaped(); this.next(); tok.addRange(c, rangeend); } } if (this.read() == T_CHAR && this.chardata == ',') this.next(); } if (this.read() == T_EOF) throw ex("parser.cc.2", this.offset); if (!useNrange && nrange) { base.subtractRanges(tok); tok = base; } tok.sortRanges(); tok.compactRanges(); //tok.dumpRanges(); /* if (this.isSet(RegularExpression.IGNORE_CASE)) tok = RangeToken.createCaseInsensitiveToken(tok); */ this.setContext(S_NORMAL); this.next(); // Skips ']' return tok; } | 46079 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46079/a0bbc4dd8c8a7fc81862f96dec1f28070b5ed1ff/RegexParser.java/clean/src/org/apache/xerces/utils/regex/RegexParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
8086,
1345,
1109,
7069,
797,
12,
6494,
999,
50,
3676,
13,
1216,
10616,
288,
3639,
333,
18,
542,
1042,
12,
55,
67,
706,
21217,
55,
1769,
3639,
333,
18,
4285,
5621,
18701,
368,
8375... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
8086,
1345,
1109,
7069,
797,
12,
6494,
999,
50,
3676,
13,
1216,
10616,
288,
3639,
333,
18,
542,
1042,
12,
55,
67,
706,
21217,
55,
1769,
3639,
333,
18,
4285,
5621,
18701,
368,
8375... | |
super(s, e); | super(s); | public ServerException(String s, Exception e) { super(s, e); } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/fd6a57fe2ed88cedb0f331b4b49081272bc198c5/ServerException.java/buggy/core/src/classpath/java/java/rmi/ServerException.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
25305,
12,
780,
272,
16,
1185,
425,
13,
225,
288,
565,
2240,
12,
87,
1769,
225,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
25305,
12,
780,
272,
16,
1185,
425,
13,
225,
288,
565,
2240,
12,
87,
1769,
225,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
new ResultsFrame(bugs).setVisible(true); | new ResultsFrame(bugs, pckg.getProject()).setVisible(true); | public void run() { new ResultsFrame(bugs).setVisible(true); } | 10715 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10715/2885faa685b24cf3a7cdfaec354c7ab03270259d/RegularMenuBuilder.java/clean/bluej/src/edu/umd/cs/findbugs/bluej/RegularMenuBuilder.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
20982,
202,
482,
918,
1086,
1435,
6862,
9506,
202,
95,
6862,
6862,
202,
2704,
10351,
3219,
12,
19381,
2934,
542,
6207,
12,
3767,
1769,
6862,
9506,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
20982,
202,
482,
918,
1086,
1435,
6862,
9506,
202,
95,
6862,
6862,
202,
2704,
10351,
3219,
12,
19381,
2934,
542,
6207,
12,
3767,
1769,
6862,
9506,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-10... |
if (BoolUtils.isTrue(condition)) { | if(BoolUtils.isTrue(condition)){ | private static boolean whileStatementMustThrowException( PsiWhileStatement whileStatement) { final PsiExpression condition = whileStatement.getCondition(); if (BoolUtils.isTrue(condition)) { final PsiStatement body = whileStatement.getBody(); if (statementMustThrowException( body)) { return true; } } return false; } | 17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/fc3fc1341db4aa6d26930bf45116ec44c28fc569/InitializationUtils.java/buggy/plugins/InspectionGadgets/src/com/siyeh/ig/psiutils/InitializationUtils.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
760,
1250,
1323,
3406,
10136,
8282,
503,
12,
453,
7722,
15151,
3406,
1323,
3406,
13,
288,
3639,
727,
453,
7722,
2300,
2269,
273,
1323,
3406,
18,
588,
3418,
5621,
3639,
309,
12,
7464... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1250,
1323,
3406,
10136,
8282,
503,
12,
453,
7722,
15151,
3406,
1323,
3406,
13,
288,
3639,
727,
453,
7722,
2300,
2269,
273,
1323,
3406,
18,
588,
3418,
5621,
3639,
309,
12,
7464... |
public void run() { int seconds = 120; // give up after 2 min while (plugin == null) { // 1s polling try { Thread.sleep(1000); } catch (InterruptedException e) { } if (seconds-- <= 0) return; } if (plugin instanceof FredPlugin) { FredPlugin plug = ((FredPlugin)plugin); //if (plug.handles(FredPlugin.handleFproxy)) ((FredPlugin)plugin).runPlugin(pr); } // If not FredPlugin, then the whole thing is aborted, // and then this method will return, killing the thread pm.removePlugin(this); } | 51834 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51834/846fd65282fad12ebf541ad2616fb154f63fd8f4/PluginHandler.java/clean/src/freenet/pluginmanager/PluginHandler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
1086,
1435,
288,
1082,
202,
474,
3974,
273,
15743,
31,
368,
8492,
731,
1839,
576,
1131,
1082,
202,
17523,
261,
4094,
422,
446,
13,
288,
9506,
202,
759,
404,
87,
13708,
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,
1086,
1435,
288,
1082,
202,
474,
3974,
273,
15743,
31,
368,
8492,
731,
1839,
576,
1131,
1082,
202,
17523,
261,
4094,
422,
446,
13,
288,
9506,
202,
759,
404,
87,
13708,
9... | ||
public static String[] writeWordWrap(String input, String sepRegex, String separator, int width) { width--; if (input.length()<=width) return new String[]{input}; String[] parts = input.split(sepRegex); StringBuffer currentLine = new StringBuffer(); List lines = new ArrayList(); for (int i = 0; i < parts.length; i++) { String word = parts[i]; if (word!=null && word.length()>0) { if (i < (parts.length-1)) word = word + separator; int wordLength = word.length(); if (wordLength+currentLine.length() > width) { if (wordLength > width) { do { int chunkSize = Math.min(width-currentLine.length(),wordLength); currentLine.append(word.substring(0,chunkSize)); if (currentLine.length()>=width) { lines.add(currentLine.toString()); currentLine.setLength(0); } word = word.substring(chunkSize); wordLength = word.length(); } while (wordLength+currentLine.length() > width); } else { lines.add(currentLine.toString()); currentLine.setLength(0); | public static String[] writeWordWrap(String input, String sepRegex, int width) { List lines = new ArrayList(); Pattern p = Pattern.compile(sepRegex); int start = 0; while (start < input.length()) { if (input.charAt(start)=='\n') start++; int splitPoint = start+width; if (splitPoint > input.length()) splitPoint=input.length(); else { int newline = input.indexOf('\n',start); if (newline>start && newline<splitPoint) { splitPoint = newline; } else { while (splitPoint>start) { char c = input.charAt(splitPoint); Matcher m = p.matcher(""+c); if (m.matches()) break; splitPoint--; | public static String[] writeWordWrap(String input, String sepRegex, String separator, int width) { width--; // because of some weird start-at-zero thingy - if you pass 60, we must work with 59. if (input.length()<=width) return new String[]{input}; String[] parts = input.split(sepRegex); StringBuffer currentLine = new StringBuffer(); List lines = new ArrayList(); for (int i = 0; i < parts.length; i++) { String word = parts[i]; if (word!=null && word.length()>0) { if (i < (parts.length-1)) word = word + separator; int wordLength = word.length(); if (wordLength+currentLine.length() > width) { if (wordLength > width) { // must split word do { int chunkSize = Math.min(width-currentLine.length(),wordLength); currentLine.append(word.substring(0,chunkSize)); if (currentLine.length()>=width) { lines.add(currentLine.toString()); currentLine.setLength(0); } word = word.substring(chunkSize); wordLength = word.length(); } while (wordLength+currentLine.length() > width); } else { lines.add(currentLine.toString()); currentLine.setLength(0); } } currentLine.append(word); } } if (currentLine.length()>0) lines.add(currentLine.toString()); return (String[])lines.toArray(new String[0]); } | 50397 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50397/674f7f2565f05cab740ca20faf8dce745bfca0a4/RichSequenceFormat.java/buggy/src/org/biojavax/bio/seq/io/RichSequenceFormat.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
760,
514,
8526,
1045,
3944,
2964,
12,
780,
810,
16,
514,
5478,
6628,
16,
514,
4182,
16,
509,
1835,
13,
288,
5411,
1835,
413,
31,
368,
2724,
434,
2690,
20843,
787,
17,
270,
17,
7... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
760,
514,
8526,
1045,
3944,
2964,
12,
780,
810,
16,
514,
5478,
6628,
16,
514,
4182,
16,
509,
1835,
13,
288,
5411,
1835,
413,
31,
368,
2724,
434,
2690,
20843,
787,
17,
270,
17,
7... |
ITranslationUnit myTranslationUnit; ICElement myElement; Stack missing=new Stack(); int x; myTranslationUnit=CProjectHelper.findTranslationUnit(testProject,"exetest.c"); for (x=0;x<expectedStringList.length;x++) { myElement=myTranslationUnit.getElementAtLine(expectedLines[x]); if (myElement==null) missing.push(expectedStringList[x]); else { if (expectedStringList[x].equals("mystruct_t")) { assertTrue("PR:23603 expected:" + expectedStringList[x] + " Got:" + myElement.getElementName(), expectedStringList[x].equals(myElement.getElementName())); } else { assertTrue("Expected:" + expectedStringList[x] + " Got:" + myElement.getElementName(), expectedStringList[x].equals(myElement.getElementName())); } } } if (!missing.empty()) { String output=new String("PR: 23603 Could not get elements: "); while (!missing.empty()) output+=missing.pop() + " "; assertTrue(output, false); } | ITranslationUnit myTranslationUnit; ICElement myElement; Stack missing = new Stack(); int x; myTranslationUnit = CProjectHelper.findTranslationUnit(testProject, "exetest.c"); | public void testGetElementAtLine() throws CoreException { ITranslationUnit myTranslationUnit; ICElement myElement; Stack missing=new Stack(); int x; myTranslationUnit=CProjectHelper.findTranslationUnit(testProject,"exetest.c"); for (x=0;x<expectedStringList.length;x++) { myElement=myTranslationUnit.getElementAtLine(expectedLines[x]); if (myElement==null) missing.push(expectedStringList[x]); else { if (expectedStringList[x].equals("mystruct_t")) { assertTrue("PR:23603 expected:" + expectedStringList[x] + " Got:" + myElement.getElementName(), expectedStringList[x].equals(myElement.getElementName())); } else { assertTrue("Expected:" + expectedStringList[x] + " Got:" + myElement.getElementName(), expectedStringList[x].equals(myElement.getElementName())); } } } if (!missing.empty()) { String output=new String("PR: 23603 Could not get elements: "); while (!missing.empty()) output+=missing.pop() + " "; assertTrue(output, false); } } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/cd284ca6ec787a9d394dc976606f837a515f2339/TranslationUnitTests.java/clean/core/org.eclipse.cdt.core.tests/model/org/eclipse/cdt/core/model/tests/TranslationUnitTests.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
967,
1046,
861,
1670,
1435,
1216,
30015,
288,
3639,
467,
6717,
2802,
3399,
6717,
2802,
31,
3639,
26899,
1046,
3399,
1046,
31,
3639,
7283,
3315,
33,
2704,
7283,
5621,
3639,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
967,
1046,
861,
1670,
1435,
1216,
30015,
288,
3639,
467,
6717,
2802,
3399,
6717,
2802,
31,
3639,
26899,
1046,
3399,
1046,
31,
3639,
7283,
3315,
33,
2704,
7283,
5621,
3639,
... |
public CacheItem(Object data, String name) { this.name = name; | public CacheItem(Object data) { | public CacheItem(Object data, String name) { this.name = name; this.data = data; } | 25527 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/25527/5ff3305b7d503af0196bc74bcce4c4c4dd3ef604/JarThemeSource.java/clean/src/com/itmill/toolkit/terminal/web/JarThemeSource.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
4379,
1180,
12,
921,
501,
16,
514,
508,
13,
288,
1082,
202,
2211,
18,
529,
273,
508,
31,
1082,
202,
2211,
18,
892,
273,
501,
31,
202,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
4379,
1180,
12,
921,
501,
16,
514,
508,
13,
288,
1082,
202,
2211,
18,
529,
273,
508,
31,
1082,
202,
2211,
18,
892,
273,
501,
31,
202,
202,
97,
2,
-100,
-100,
-100,
-100,
... |
return ""; | return "On/Off"; | public String getUnits() { return ""; } | 48870 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48870/16ec1ee54af82efd3e8d6ca756d0f97f8a7c12e0/EcuSwitchConvertorImpl.java/clean/src/enginuity/logger/definition/EcuSwitchConvertorImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
336,
7537,
1435,
288,
3639,
327,
315,
1398,
19,
7210,
14432,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
336,
7537,
1435,
288,
3639,
327,
315,
1398,
19,
7210,
14432,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
public RubyObject get(String id, RubyObject value, RubyGlobalEntry entry) { return RubyFixnum.newFixnum(entry.getRuby(), entry.getRuby().getSafeLevel()); | public RubyObject get(Ruby ruby, RubyGlobalEntry entry) { return RubyFixnum.newFixnum(ruby, ruby.getSafeLevel()); | public RubyObject get(String id, RubyObject value, RubyGlobalEntry entry) { return RubyFixnum.newFixnum(entry.getRuby(), entry.getRuby().getSafeLevel()); } | 45221 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45221/4e4bb40b2eb2d38881d15ca8ef7cda4c34323793/RubyGlobal.java/clean/org/jruby/RubyGlobal.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
19817,
921,
336,
12,
780,
612,
16,
19817,
921,
460,
16,
19817,
5160,
1622,
1241,
13,
288,
5411,
327,
19817,
8585,
2107,
18,
2704,
8585,
2107,
12,
4099,
18,
588,
54,
10340,
9334,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
19817,
921,
336,
12,
780,
612,
16,
19817,
921,
460,
16,
19817,
5160,
1622,
1241,
13,
288,
5411,
327,
19817,
8585,
2107,
18,
2704,
8585,
2107,
12,
4099,
18,
588,
54,
10340,
9334,
1... |
writer = new OutputStreamWriter(out); } | this.out = out; } | public MarcStreamWriter(OutputStream out) { writer = new OutputStreamWriter(out); } | 54133 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54133/d012a4d22da022d0e2ffef1f49404d8568fab6c2/MarcStreamWriter.java/clean/src/org/marc4j/MarcStreamWriter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
490,
11828,
29421,
12,
4632,
596,
13,
288,
202,
202,
6299,
273,
394,
24248,
12,
659,
1769,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
490,
11828,
29421,
12,
4632,
596,
13,
288,
202,
202,
6299,
273,
394,
24248,
12,
659,
1769,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
.appendScript("');"); | .appendScript(");"); | public void setClassName(String elementId, String className) { ScriptBuffer script = createScriptBuffer(); script.appendScript("DWRUtil.setClassName('") .appendData(elementId) .appendScript("', '") .appendData(className) .appendScript("');"); addScript(script); } | 45384 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45384/d1b2e32813663d0a863f97702a7ee955c735eebc/DwrUtil.java/buggy/java/org/directwebremoting/proxy/dwrutil/DwrUtil.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
444,
3834,
12,
780,
930,
548,
16,
514,
2658,
13,
565,
288,
3639,
7739,
1892,
2728,
273,
752,
3651,
1892,
5621,
3639,
2728,
18,
6923,
3651,
2932,
40,
7181,
1304,
18,
542,
3834... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3834,
12,
780,
930,
548,
16,
514,
2658,
13,
565,
288,
3639,
7739,
1892,
2728,
273,
752,
3651,
1892,
5621,
3639,
2728,
18,
6923,
3651,
2932,
40,
7181,
1304,
18,
542,
3834... |
Timer timer = new Timer(true); | startPing(); | protected void initialize(IProgressMonitor monitor) { Trace.trace(Trace.INFO, "GeronimoServerBehavior.initialize()"); Timer timer = new Timer(true); // timer.schedule(new UpdateServerStateTask(this), 0, // TIMER_TASK_INTERVAL * 1000); } | 10123 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/10123/27f1cbef3ab063e9c54c8dd534f4128b590070c2/GeronimoServerBehaviour.java/clean/plugins/org.apache.geronimo.devtools.eclipse.core/src/org/apache/geronimo/core/internal/GeronimoServerBehaviour.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
4046,
12,
45,
5491,
7187,
6438,
13,
288,
202,
202,
3448,
18,
5129,
12,
3448,
18,
5923,
16,
315,
43,
264,
265,
381,
83,
2081,
9212,
18,
11160,
1435,
8863,
202,
202,
677... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4046,
12,
45,
5491,
7187,
6438,
13,
288,
202,
202,
3448,
18,
5129,
12,
3448,
18,
5923,
16,
315,
43,
264,
265,
381,
83,
2081,
9212,
18,
11160,
1435,
8863,
202,
202,
677... |
Assert.assertEquals( 0, atav1.compareTo( atav2 ) ); } | assertEquals( 0, atav1.compareTo( atav2 ) ); } | public void testCompareToEqualsCase() throws InvalidNameException { AttributeTypeAndValue atav1 = new AttributeTypeAndValue( "a", "b" ); AttributeTypeAndValue atav2 = new AttributeTypeAndValue( "A", "b" ); Assert.assertEquals( 0, atav1.compareTo( atav2 ) ); } | 54578 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54578/34d16a3366af953bef4b3d5f4cf0e7c6bda29ba6/AttributeTypeAndValueTest.java/buggy/ldap/src/test/java/org/apache/directory/shared/ldap/name/AttributeTypeAndValueTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
8583,
774,
8867,
2449,
1435,
1216,
1962,
26771,
565,
288,
3639,
26414,
30154,
225,
396,
90,
21,
273,
394,
26414,
30154,
12,
315,
69,
3113,
315,
70,
6,
11272,
3639,
26414,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
8583,
774,
8867,
2449,
1435,
1216,
1962,
26771,
565,
288,
3639,
26414,
30154,
225,
396,
90,
21,
273,
394,
26414,
30154,
12,
315,
69,
3113,
315,
70,
6,
11272,
3639,
26414,... |
throw org.postgresql.Driver.notImplemented(); | throw org.postgresql.Driver.notImplemented(this.getClass(), "setBigDecimal(String,BigDecimal)"); | public void setBigDecimal(String parameterName, BigDecimal x) throws SQLException { throw org.postgresql.Driver.notImplemented(); } | 49868 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49868/9021170b912463b937128290d58c575400d02fcf/AbstractJdbc3Statement.java/buggy/org/postgresql/jdbc3/AbstractJdbc3Statement.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
444,
29436,
12,
780,
15524,
16,
8150,
619,
13,
1216,
6483,
565,
288,
3639,
604,
2358,
18,
2767,
24330,
18,
4668,
18,
902,
8644,
12,
2211,
18,
588,
797,
9334,
315,
542,
29436,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
444,
29436,
12,
780,
15524,
16,
8150,
619,
13,
1216,
6483,
565,
288,
3639,
604,
2358,
18,
2767,
24330,
18,
4668,
18,
902,
8644,
12,
2211,
18,
588,
797,
9334,
315,
542,
29436,... |
"View results here -> http: | "View results here -> " + baseURLString + "?log=log20020206120000", | public void testCreateMessage() { EmailPublisher publisher = new LinkEmailPublisher(); publisher.setBuildResultsURL( "http://mybuildserver.com:8080/buildservlet/BuildServlet"); assertEquals( "View results here -> http://mybuildserver.com:8080/buildservlet/BuildServlet?log=log20020206120000", publisher.createMessage(successLogHelper)); } | 55334 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55334/6b9d78da7d9dd3c8326fb1b159e897d7caa7bc7e/LinkEmailPublisherTest.java/buggy/main/test/net/sourceforge/cruisecontrol/publishers/LinkEmailPublisherTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
1684,
1079,
1435,
288,
3639,
8166,
15960,
12855,
273,
394,
4048,
4134,
15960,
5621,
3639,
12855,
18,
542,
3116,
3447,
1785,
12,
5411,
315,
2505,
2207,
4811,
3510,
3567,
18,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
1684,
1079,
1435,
288,
3639,
8166,
15960,
12855,
273,
394,
4048,
4134,
15960,
5621,
3639,
12855,
18,
542,
3116,
3447,
1785,
12,
5411,
315,
2505,
2207,
4811,
3510,
3567,
18,... |
setStatusBarText("Waiting to begin Deployment phase..."); | setStatusBarText(Messages.getString("DeploymentDisplay.waitingForDeploymentPhase")); | public void gamePhaseChange(GameEvent ev) { clientgui.bv.markDeploymentHexesFor(null); // Are we ignoring events? if ( this.isIgnoringEvents() ) { return; } if (client.game.getPhase() == Game.PHASE_DEPLOYMENT) { setStatusBarText("Waiting to begin Deployment phase..."); } } | 4135 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4135/c9f0f1d2e5ceb1c577004355102dc4109baf3a49/DeploymentDisplay.java/buggy/megamek/src/megamek/client/ui/AWT/DeploymentDisplay.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
7920,
11406,
3043,
12,
12496,
1133,
2113,
13,
288,
3639,
1004,
20292,
18,
70,
90,
18,
3355,
6733,
7037,
281,
1290,
12,
2011,
1769,
3639,
368,
12520,
732,
14398,
2641,
35,
3639,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
7920,
11406,
3043,
12,
12496,
1133,
2113,
13,
288,
3639,
1004,
20292,
18,
70,
90,
18,
3355,
6733,
7037,
281,
1290,
12,
2011,
1769,
3639,
368,
12520,
732,
14398,
2641,
35,
3639,... |
case '&': | case '&': | static String escapeChars(String input) { StringBuffer sb = new StringBuffer(); for (int i = 0; i < input.length(); i++) { char c = input.charAt(i); switch (c) { case '&': sb.append("&"); break; case '<': sb.append("<"); break; case '>': sb.append(">"); break; case '\'': sb.append("'"); break; case '"': sb.append("""); break; default: sb.append(c); break; } } return sb.toString(); } | 54769 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54769/40effaf129249b2248e897d030f9998321d4020f/XMLEncoder.java/clean/modules/beans/src/main/java/java/beans/XMLEncoder.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
760,
514,
4114,
7803,
12,
780,
810,
13,
288,
3639,
6674,
2393,
273,
394,
6674,
5621,
7734,
364,
261,
474,
277,
273,
374,
31,
277,
411,
810,
18,
2469,
5621,
277,
27245,
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,
760,
514,
4114,
7803,
12,
780,
810,
13,
288,
3639,
6674,
2393,
273,
394,
6674,
5621,
7734,
364,
261,
474,
277,
273,
374,
31,
277,
411,
810,
18,
2469,
5621,
277,
27245,
288,
5411,
1149,
... |
final long checkSum = mLineBlockChecksums[aI][aILine]; | final long[] iCheckSums = mLineBlockChecksums[aI]; final long[] jCheckSums = mLineBlockChecksums[aJ]; | private int findDuplicateFromLine( final int aI, final int aJ, final int aILine) { // Using something more advanced like Boyer-Moore might be a // good idea... final long checkSum = mLineBlockChecksums[aI][aILine]; final int iBlockCount = mLineBlockChecksums[aI].length; final int jBlockCount = mLineBlockChecksums[aJ].length; for (int jBlock = 0; jBlock < jBlockCount; jBlock++) { if (aI == aJ && aILine >= jBlock) { continue; } if (mLineBlockChecksums[aJ][jBlock] != checkSum) { continue; } int duplicateLines = verifiyDuplicateLines(aI, aJ, aILine, jBlock); if (duplicateLines >= mMin) { reportDuplicate(duplicateLines, aILine, mFiles[aJ], jBlock); // skip to end of equivalent section return aILine + duplicateLines; } } return aILine; } | 50482 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50482/2cc0132ad9483db2b0c420d2eb056fcf7ea55f3d/StrictDuplicateCodeCheck.java/buggy/src/checkstyle/com/puppycrawl/tools/checkstyle/checks/duplicates/StrictDuplicateCodeCheck.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
509,
1104,
11826,
1265,
1670,
12,
3639,
727,
509,
279,
45,
16,
727,
509,
279,
46,
16,
727,
509,
279,
45,
1670,
13,
565,
288,
3639,
368,
11637,
5943,
1898,
16111,
3007,
605,
13372,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
509,
1104,
11826,
1265,
1670,
12,
3639,
727,
509,
279,
45,
16,
727,
509,
279,
46,
16,
727,
509,
279,
45,
1670,
13,
565,
288,
3639,
368,
11637,
5943,
1898,
16111,
3007,
605,
13372,... |
_set_delegate(delegate); | public _NamingContextStub(Delegate delegate) { super(); _set_delegate(delegate); } | 47947 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47947/786c2becb06b79e85766f813e56e2ca9530695b9/_NamingContextStub.java/buggy/org/omg/CosNaming/_NamingContextStub.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
389,
24102,
1042,
11974,
12,
9586,
7152,
13,
225,
288,
565,
2240,
5621,
377,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
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,
282,
1071,
389,
24102,
1042,
11974,
12,
9586,
7152,
13,
225,
288,
565,
2240,
5621,
377,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... | |
public void insertUpdate(DocumentEvent e) {destinationAddressChanged();} | public void insertUpdate(DocumentEvent e) {numRepetitionsChanged();} | public void insertUpdate(DocumentEvent e) {destinationAddressChanged();} | 6866 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6866/9e9be5a3bb81a0b1c1c70f48f224f1da177da9c9/SimpleSetupPanel.java/buggy/gui/experiment/SimpleSetupPanel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
2243,
1891,
12,
2519,
1133,
425,
13,
288,
10590,
1887,
5033,
5621,
97,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
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,
225,
202,
482,
918,
2243,
1891,
12,
2519,
1133,
425,
13,
288,
10590,
1887,
5033,
5621,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
className = (String) classLookup.get(type); | className = classLookup.get(type); | public static ChoiceManagerList getChoiceManager ( PObject aPObject, String theChoices, PlayerCharacter aPC) { if (!mapconstructed) { constructMap(); } final String choiceString; if(theChoices != null && theChoices.length() > 0) { choiceString = theChoices; } else { choiceString = aPObject.getChoiceString(); } if (choiceString == null || choiceString.length() == 0) { return null; } List mainList = Arrays.asList(choiceString.split("[|]")); /* Find the first element of the array that does not contain an * equals sign, this is the type of chooser. */ int i = 0; while (i <= mainList.size() - 1 && ((String) mainList.get(i)).indexOf("=") > 0 && !(((String) mainList.get(i)).startsWith("FEAT=") || ((String) mainList.get(i)).startsWith("FEAT."))) { i++; } /* Use the name of the chooser to look up the full canonical * class name of the ChoiceManager that handles that type of chooser */ String type = (i >= mainList.size()) ? "MISC" : (String) mainList.get(i); if (type.startsWith("FEAT=") || type.startsWith("FEAT.")) { type = "SINGLEFEAT"; } String className = (String) classLookup.get(type); if (className == null) { if (Globals.weaponTypesContains(type)) { type = "WEAPONPROF"; className = (String) classLookup.get(type); } else { type = "MISC"; className = (String) classLookup.get(type); } } /* Construct and return the ChoiceManager */ try { Class aClass = Class.forName(className); Class[] argsClass = { PObject.class, choiceString.getClass(), aPC.getClass() }; Object[] argsObject = {aPObject, choiceString, aPC}; Constructor constructor = aClass.getConstructor(argsClass); ChoiceManagerList cm = (ChoiceManagerList) constructor.newInstance(argsObject); return cm; } catch (ClassNotFoundException e) { Logging.errorPrint("Can't create Choice Manager: " + type + " Class not found", e); } catch (InstantiationException e) { Logging.errorPrint("Can't create Choice Manager: " + type + " Can't instantiate class", e); } catch (IllegalAccessException e) { Logging.errorPrint("Can't create Choice Manager: " + type + " Illegal access", e); } catch (NoSuchMethodException e) { Logging.errorPrint("Can't create Choice Manager: " + type + " no constructor found", e); } catch (InvocationTargetException e) { Logging.errorPrint("Can't create Choice Manager: " + type + " class threw an error", e); } return null; } | 48301 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48301/e68beba0b8f33d1c2a9953dbe1729d156fec02cc/ChooserUtilities.java/buggy/code/src/java/pcgen/core/chooser/ChooserUtilities.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
16432,
1318,
682,
336,
10538,
1318,
261,
1082,
202,
52,
921,
540,
279,
52,
921,
16,
1082,
202,
780,
1850,
326,
17442,
16,
1082,
202,
12148,
7069,
279,
3513,
13,
202,
95,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
16432,
1318,
682,
336,
10538,
1318,
261,
1082,
202,
52,
921,
540,
279,
52,
921,
16,
1082,
202,
780,
1850,
326,
17442,
16,
1082,
202,
12148,
7069,
279,
3513,
13,
202,
95,
... |
} | } | public void setEchoChar(char echo) { this.echoChar = echo; // TODO } // setEchoChar() | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/50dc6879c9be89f646fdff68c58f785e3dc0b90e/JPasswordField.java/clean/core/src/classpath/javax/javax/swing/JPasswordField.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
444,
19704,
2156,
12,
3001,
3376,
13,
288,
202,
202,
2211,
18,
12946,
2156,
273,
3376,
31,
202,
202,
759,
2660,
202,
97,
368,
444,
19704,
2156,
1435,
2,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
444,
19704,
2156,
12,
3001,
3376,
13,
288,
202,
202,
2211,
18,
12946,
2156,
273,
3376,
31,
202,
202,
759,
2660,
202,
97,
368,
444,
19704,
2156,
1435,
2,
-100,
-100,
-100,... |
else throw new IllegalArgumentException(); | else return -1; | public synchronized long getTime(int index) { Integer i = new Integer(index); LimitedRangeIntByteArrayMapElement wrapper = (LimitedRangeIntByteArrayMapElement) contents.get(i); if(wrapper != null) return wrapper.createdTime; else throw new IllegalArgumentException(); } | 45341 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45341/f3e8db3d18ab7fe6278e45269c4260e3bc7ea7aa/LimitedRangeIntByteArrayMap.java/buggy/src/freenet/support/LimitedRangeIntByteArrayMap.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
1525,
6135,
12,
474,
770,
13,
288,
3639,
2144,
277,
273,
394,
2144,
12,
1615,
1769,
3639,
7214,
329,
2655,
1702,
8826,
863,
1046,
4053,
273,
261,
3039,
329,
2655,
1702,
8826,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
3852,
1525,
6135,
12,
474,
770,
13,
288,
3639,
2144,
277,
273,
394,
2144,
12,
1615,
1769,
3639,
7214,
329,
2655,
1702,
8826,
863,
1046,
4053,
273,
261,
3039,
329,
2655,
1702,
8826,
... |
if (lhs == null) { return; } | public void visitBinaryExpression(@NotNull PsiBinaryExpression expression) { super.visitBinaryExpression(expression); final PsiJavaToken sign = expression.getOperationSign(); if(sign == null){ return; } final IElementType tokenType = sign.getTokenType(); if(!bitwiseTokens.contains(tokenType)) { return; } final PsiType expressionType = expression.getType(); if (expressionType == null) { return; } final PsiExpression rhs = expression.getROperand(); if (rhs == null) { return; } final PsiType rhsType = rhs.getType(); if (rhsType == null) { return; } if (rhsType.equals(PsiType.BOOLEAN) || rhsType.equalsToText("java.lang.Boolean")) { return; } final PsiExpression lhs = expression.getLOperand(); if (lhs == null) { return; } final PsiType lhsType = lhs.getType(); if (lhsType == null) { return; } if (lhsType.equals(PsiType.BOOLEAN) || lhsType.equalsToText("java.lang.Boolean")) { return; } final boolean isPointless; if (tokenType.equals(JavaTokenType.AND)) { isPointless = andExpressionIsPointless(lhs, rhs, expressionType); } else if (tokenType.equals(JavaTokenType.OR)) { isPointless = orExpressionIsPointless(lhs, rhs, expressionType); } else if (tokenType.equals(JavaTokenType.XOR)) { isPointless = xorExpressionIsPointless(lhs, rhs, expressionType); } else if (tokenType.equals(JavaTokenType.LTLT) || tokenType.equals(JavaTokenType.GTGT) || tokenType.equals(JavaTokenType.GTGTGT)) { isPointless = shiftExpressionIsPointless(rhs, expressionType); } else { isPointless = false; } if (!isPointless) { return; } registerError(expression); } | 17306 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17306/10dfc0821a579a6a0ff949a64d378572f57a4625/PointlessBitwiseExpressionInspection.java/clean/plugins/InspectionGadgets/src/com/siyeh/ig/bitwise/PointlessBitwiseExpressionInspection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
3757,
5905,
2300,
26964,
5962,
453,
7722,
5905,
2300,
2652,
13,
288,
5411,
2240,
18,
11658,
5905,
2300,
12,
8692,
1769,
5411,
727,
453,
7722,
5852,
1345,
1573,
273,
2652,
18,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
918,
3757,
5905,
2300,
26964,
5962,
453,
7722,
5905,
2300,
2652,
13,
288,
5411,
2240,
18,
11658,
5905,
2300,
12,
8692,
1769,
5411,
727,
453,
7722,
5852,
1345,
1573,
273,
2652,
18,
5... | |
if (!child.isFullyChecked()) return false; | if (!child.isFullyChecked()) { return false; } | boolean isFullyChecked() { if (getItems().size() != getCheckedItems().size()) return false; for (int i = 0; i < children.size(); i++) { ShortcutMenu child = (ShortcutMenu) children.get(i); if (!child.isFullyChecked()) return false; } return true; } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/fa4a8cff0e027f8d3c6b1fcb92b30f46767dd191/CustomizePerspectiveDialog.java/buggy/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/dialogs/CustomizePerspectiveDialog.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1250,
353,
16999,
11454,
1435,
288,
5411,
309,
261,
588,
3126,
7675,
1467,
1435,
480,
336,
11454,
3126,
7675,
1467,
10756,
7734,
327,
629,
31,
5411,
364,
261,
474,
277,
273,
374,
31,
277,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1250,
353,
16999,
11454,
1435,
288,
5411,
309,
261,
588,
3126,
7675,
1467,
1435,
480,
336,
11454,
3126,
7675,
1467,
10756,
7734,
327,
629,
31,
5411,
364,
261,
474,
277,
273,
374,
31,
277,... |
RubyArray result = RubyArray.newArray(getRuntime(), fields.length); | RubyArray result = getRuntime().newArray(fields.length); | public RubyArray fields() { Field[] fields = javaClass.getFields(); RubyArray result = RubyArray.newArray(getRuntime(), fields.length); for (int i = 0; i < fields.length; i++) { Field field = fields[i]; result.append(RubyString.newString(getRuntime(), field.getName())); } return result; } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/870e1da9b41bfdbae259e1fc5f18fc8b76686998/JavaClass.java/buggy/src/org/jruby/javasupport/JavaClass.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
19817,
1076,
1466,
1435,
288,
3639,
2286,
8526,
1466,
273,
2252,
797,
18,
588,
2314,
5621,
3639,
19817,
1076,
563,
273,
18814,
7675,
2704,
1076,
12,
2821,
18,
2469,
1769,
3639,
364,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
19817,
1076,
1466,
1435,
288,
3639,
2286,
8526,
1466,
273,
2252,
797,
18,
588,
2314,
5621,
3639,
19817,
1076,
563,
273,
18814,
7675,
2704,
1076,
12,
2821,
18,
2469,
1769,
3639,
364,
... |
RMINotificationListener notifListener = (RMINotificationListener)notifications.remove(listener); | MyRMINotificationListener notifListener = (MyRMINotificationListener) notifications.remove(listener); | public void removeNotificationListener(ObjectName objectName, ObjectNotificationListener listener, ObjectNotificationFilter filter, Object handback){ RMINotificationListener notifListener = (RMINotificationListener)notifications.remove(listener); assert notifListener != null; try { rmiAdaptor.removeNotificationListener(toJMXObjectName(objectName), notifListener); } catch (Exception e) { throw new RuntimeException(e); } } | 54569 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54569/905b70804989493ce05d502f177d1b2c9ffea1ea/JBossServerConnection.java/clean/jmanage/modules/jboss/src/main/java/org/jmanage/core/modules/jboss/JBossServerConnection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1206,
4386,
2223,
12,
16707,
12282,
16,
4766,
6647,
1033,
4386,
2223,
2991,
16,
4766,
6647,
1033,
4386,
1586,
1034,
16,
4766,
6647,
1033,
948,
823,
15329,
3639,
534,
6236,
352,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1206,
4386,
2223,
12,
16707,
12282,
16,
4766,
6647,
1033,
4386,
2223,
2991,
16,
4766,
6647,
1033,
4386,
1586,
1034,
16,
4766,
6647,
1033,
948,
823,
15329,
3639,
534,
6236,
352,
... |
int nameOffset = 0; int nameEndOffset = 0; nameOffset = namedElement.getNameOffset(); nameEndOffset = namedElement.getNameEndOffset(); open( storage.getResource(), nameOffset, nameEndOffset - nameOffset ); | clearStatusLine(); open( storage.getResource(), nameOffset, nameLength ); | public void run() { final SelSearchNode selNode = getSelectedStringFromEditor(); if(selNode == null) { return; } final Storage storage = new Storage(); IRunnableWithProgress runnable = new IRunnableWithProgress() { public void run(IProgressMonitor monitor) { IFile resourceFile = fEditor.getInputFile(); projectName = findProjectName(resourceFile); IParser parser = setupParser(resourceFile); int selectionStart = selNode.selStart; int selectionEnd = selNode.selEnd; IParser.ISelectionParseResult result = null; IASTOffsetableNamedElement node = null; try{ result = parser.parse(selectionStart,selectionEnd); if( result != null ) node = result.getOffsetableNamedElement(); } catch (ParseError er){} catch ( VirtualMachineError vmErr){ if (vmErr instanceof OutOfMemoryError){ org.eclipse.cdt.internal.core.model.Util.log(null, "Open Declarations Out Of Memory error: " + vmErr.getMessage() + " on File: " + resourceFile.getName(), ICLogConstants.CDT); //$NON-NLS-1$ //$NON-NLS-2$ } } catch (Exception ex){} finally{ if (node == null){ return; } } storage.setFileName( result.getFilename() ); storage.setElement( node ); storage.setResource( ParserUtil.getResourceForFilename( result.getFilename() ) ); return; } private String findProjectName(IFile resourceFile) { if( resourceFile == null ) return ""; //$NON-NLS-1$ IProject [] projects = ResourcesPlugin.getWorkspace().getRoot().getProjects(); for( int i = 0; i < projects.length; ++i ) { if( projects[i].contains(resourceFile) ) return projects[i].getName(); } return ""; //$NON-NLS-1$ } }; try { ProgressMonitorDialog progressMonitor = new ProgressMonitorDialog(getShell()); progressMonitor.run(true, true, runnable); IASTOffsetableNamedElement namedElement = storage.getNamedElement(); if( namedElement == null ){ operationNotAvailable(); return; } else { clearStatusLine(); } if( storage.getResource() != null ) { int nameOffset = 0; int nameEndOffset = 0; nameOffset = namedElement.getNameOffset(); nameEndOffset = namedElement.getNameEndOffset(); open( storage.getResource(), nameOffset, nameEndOffset - nameOffset ); return; } else { String fileName = null; int nameOffset = 0; int nameEndOffset = 0; fileName = storage.getFileName(); nameOffset = namedElement.getNameOffset(); nameEndOffset = namedElement.getNameEndOffset(); if (fileName != null){ open( fileName,nameOffset, nameEndOffset - nameOffset); } } } catch(Exception x) { CUIPlugin.getDefault().log(x); } } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/0fedc36b901abdb7526a0e7e27d2d481789c398a/OpenDeclarationsAction.java/buggy/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/search/actions/OpenDeclarationsAction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1086,
1435,
288,
202,
202,
6385,
4352,
2979,
907,
357,
907,
273,
16625,
780,
1265,
6946,
5621,
9506,
202,
430,
12,
1786,
907,
422,
446,
13,
288,
1082,
202,
2463,
31,
202,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1086,
1435,
288,
202,
202,
6385,
4352,
2979,
907,
357,
907,
273,
16625,
780,
1265,
6946,
5621,
9506,
202,
430,
12,
1786,
907,
422,
446,
13,
288,
1082,
202,
2463,
31,
202,... |
reader.reportError( reader.ERR_UNDEFINED_DATATYPE, baseType ); | reader.reportError( reader.ERR_UNDEFINED_DATATYPE, localName ); | protected void startSelf() { final RELAXNGReader reader = (RELAXNGReader)this.reader; super.startSelf(); final String baseType = startTag.getAttribute("type"); if( baseType==null ) { reader.reportError( reader.ERR_MISSING_ATTRIBUTE, "data", "type" ); } else { // create a type incubator if( reader.datatypeLib!=null ) {// an error is already reported if lib==null. try { typeBuilder = reader.datatypeLib.createDataTypeBuilder(baseType); if( typeBuilder==null ) reader.reportError( reader.ERR_UNDEFINED_DATATYPE, baseType ); } catch( DataTypeException dte ) { reader.reportError( reader.ERR_UNDEFINED_DATATYPE_1, baseType, dte.getMessage() ); } } } if( typeBuilder==null ) { // if an error is encountered, then typeIncubator field is left null. // In that case, set a dummy implementation so that the successive param // statements are happy. typeBuilder = new DataTypeBuilder(){ public DataType derive() { return com.sun.msv.datatype.StringType.theInstance; } public void add( String name, String value, ValidationContext context ) { // do nothing. // thereby accepts anything as a valid facet. } }; } } | 45720 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45720/7ea878914ce763ef3428e08491a3749ed52ff501/DataState.java/clean/msv/src/com/sun/msv/reader/trex/ng/DataState.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
787,
10084,
1435,
288,
202,
202,
6385,
15375,
2501,
4960,
2514,
2949,
273,
261,
15868,
2501,
4960,
2514,
13,
2211,
18,
10530,
31,
202,
202,
9565,
18,
1937,
10084,
5621,
95... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
787,
10084,
1435,
288,
202,
202,
6385,
15375,
2501,
4960,
2514,
2949,
273,
261,
15868,
2501,
4960,
2514,
13,
2211,
18,
10530,
31,
202,
202,
9565,
18,
1937,
10084,
5621,
95... |
new Node(TokenStream.NUMBER, new Integer(i))); | new Node(TokenStream.NUMBER, i)); | public Object createArrayLiteral(Object obj) { Node array; Node result; array = result = new Node(TokenStream.NEW, new Node(TokenStream.NAME, "Array")); Node temp = createNewTemp(result); result = temp; java.util.Enumeration children = ((Node) obj).getChildIterator(); Node elem = null; int i = 0; while (children.hasMoreElements()) { elem = (Node) children.nextElement(); if (elem.getType() == TokenStream.PRIMARY && elem.getInt() == TokenStream.UNDEFINED) { i++; continue; } Node addelem = new Node(TokenStream.SETELEM, createUseTemp(temp), new Node(TokenStream.NUMBER, new Integer(i)), elem); i++; result = new Node(TokenStream.COMMA, result, addelem); } /* * If the version is 120, then new Array(4) means create a new * array with 4 as the first element. In this case, we might * need to explicitly check against trailing undefined * elements in the array literal, and set the length manually * if these occur. Otherwise, we can add an argument to the * node specifying new Array() to provide the array length. * (Which will make Array optimizations involving allocating a * Java array to back the javascript array work better.) */ if (Context.getContext().getLanguageVersion() == Context.VERSION_1_2) { /* When last array element is empty, we need to set the * length explicitly, because we can't depend on SETELEM * to do it for us - because empty [,,] array elements * never set anything at all. */ if (elem != null && elem.getType() == TokenStream.PRIMARY && elem.getInt() == TokenStream.UNDEFINED) { Node setlength = new Node(TokenStream.SETPROP, createUseTemp(temp), new Node(TokenStream.STRING, "length"), new Node(TokenStream.NUMBER, new Integer(i))); result = new Node(TokenStream.COMMA, result, setlength); } } else { array.addChildToBack(new Node(TokenStream.NUMBER, new Integer(i))); } return new Node(TokenStream.COMMA, result, createUseTemp(temp)); } | 12904 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12904/e08099b6748ff1ab20ba181c566c07a93c1dde78/IRFactory.java/buggy/js/rhino/src/org/mozilla/javascript/IRFactory.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1033,
752,
1076,
6177,
12,
921,
1081,
13,
288,
3639,
2029,
526,
31,
3639,
2029,
563,
31,
3639,
526,
273,
563,
273,
394,
2029,
12,
1345,
1228,
18,
12917,
16,
21394,
394,
2029,
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,
1033,
752,
1076,
6177,
12,
921,
1081,
13,
288,
3639,
2029,
526,
31,
3639,
2029,
563,
31,
3639,
526,
273,
563,
273,
394,
2029,
12,
1345,
1228,
18,
12917,
16,
21394,
394,
2029,
12,
... |
AST tmp2209_AST_in = (AST)_t; | AST tmp2211_AST_in = (AST)_t; | public final void undostate(AST _t) throws RecognitionException { AST undostate_AST_in = (_t == ASTNULL) ? null : (AST)_t; AST __t2357 = _t; AST tmp2209_AST_in = (AST)_t; match(_t,UNDO); _t = _t.getFirstChild(); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case BLOCK_LABEL: { AST tmp2210_AST_in = (AST)_t; match(_t,BLOCK_LABEL); _t = _t.getNextSibling(); break; } case EOF: case PERIOD: case COMMA: { break; } default: { throw new NoViableAltException(_t); } } } { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case COMMA: { AST tmp2211_AST_in = (AST)_t; match(_t,COMMA); _t = _t.getNextSibling(); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case LEAVE: { AST __t2361 = _t; AST tmp2212_AST_in = (AST)_t; match(_t,LEAVE); _t = _t.getFirstChild(); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case BLOCK_LABEL: { AST tmp2213_AST_in = (AST)_t; match(_t,BLOCK_LABEL); _t = _t.getNextSibling(); break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } _t = __t2361; _t = _t.getNextSibling(); break; } case NEXT: { AST __t2363 = _t; AST tmp2214_AST_in = (AST)_t; match(_t,NEXT); _t = _t.getFirstChild(); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case BLOCK_LABEL: { AST tmp2215_AST_in = (AST)_t; match(_t,BLOCK_LABEL); _t = _t.getNextSibling(); break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } _t = __t2363; _t = _t.getNextSibling(); break; } case RETRY: { AST __t2365 = _t; AST tmp2216_AST_in = (AST)_t; match(_t,RETRY); _t = _t.getFirstChild(); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case BLOCK_LABEL: { AST tmp2217_AST_in = (AST)_t; match(_t,BLOCK_LABEL); _t = _t.getNextSibling(); break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } _t = __t2365; _t = _t.getNextSibling(); break; } case RETURN: { AST __t2367 = _t; AST tmp2218_AST_in = (AST)_t; match(_t,RETURN); _t = _t.getFirstChild(); { if (_t==null) _t=ASTNULL; if ((_tokenSet_2.member(_t.getType()))) { return_options(_t); _t = _retTree; } else if ((_t.getType()==3)) { } else { throw new NoViableAltException(_t); } } _t = __t2367; _t = _t.getNextSibling(); break; } default: { throw new NoViableAltException(_t); } } } break; } case EOF: case PERIOD: { break; } default: { throw new NoViableAltException(_t); } } } state_end(_t); _t = _retTree; _t = __t2357; _t = _t.getNextSibling(); _retTree = _t; } | 13952 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13952/f492fd11e745beb562b4e209643ba003aa8a6271/TreeParser01.java/clean/trunk/org.prorefactor.core/src/org/prorefactor/treeparser01/TreeParser01.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
22927,
669,
340,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
22927,
669,
340,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
13,
692,
446,
294,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
22927,
669,
340,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
22927,
669,
340,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
13,
692,
446,
294,... |
if(selectedWeapon == -1 && Settings.autoEndFiring) { | if (nextWeapon == -1 && Settings.autoEndFiring) { | private void fire() { int wn = client.mechD.wPan.getSelectedWeaponNum(); if (ce() == null || target == null || ce().getEquipment(wn) == null || !(ce().getEquipment(wn).getType() instanceof WeaponType)) { throw new IllegalArgumentException("current fire parameters are invalid"); } Mounted m = ce().getEquipment(wn); WeaponAttackAction waa = new WeaponAttackAction(cen, target.getTargetType(), target.getTargetId(), wn); if (((WeaponType)m.getType()).getAmmoType() != AmmoType.T_NA) { waa.setAmmoId(ce().getEquipmentNum(m.getLinked())); } attacks.addElement(waa); ce().getEquipment(wn).setUsedThisRound(true); selectedWeapon = ce().getNextWeapon(wn); // check; if there are no ready weapons, you're done. if(selectedWeapon == -1 && Settings.autoEndFiring) { ready(); return; } client.mechD.wPan.displayMech(ce()); client.mechD.wPan.selectWeapon(selectedWeapon); updateTarget(); butNext.setEnabled(false); } | 3464 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3464/deeeb0fb5b1d755e6187d0178fc5090983d5594f/FiringDisplay.java/clean/megamek/src/megamek/client/ui/AWT/FiringDisplay.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
4452,
1435,
288,
3639,
509,
341,
82,
273,
1004,
18,
3501,
343,
40,
18,
91,
4069,
18,
588,
7416,
3218,
28629,
2578,
5621,
3639,
309,
261,
311,
1435,
422,
446,
747,
1018,
422,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4452,
1435,
288,
3639,
509,
341,
82,
273,
1004,
18,
3501,
343,
40,
18,
91,
4069,
18,
588,
7416,
3218,
28629,
2578,
5621,
3639,
309,
261,
311,
1435,
422,
446,
747,
1018,
422,
... |
StringBuffer sb=new StringBuffer(); if(resolve_dns) sb.append(hostname.getHostName()); | index=hostname.indexOf('.'); if(index > 0 && !Character.isDigit(hostname.charAt(0))) sb.append(hostname.substring(0, index)); | public static String shortName(InetAddress hostname) { if(hostname == null) return null; StringBuffer sb=new StringBuffer(); if(resolve_dns) sb.append(hostname.getHostName()); else sb.append(hostname.getHostAddress()); return sb.toString(); } | 48949 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/48949/03f28a3721cc00416d5f63118f111d949e2e1e0f/Util.java/buggy/src/org/jgroups/util/Util.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
19276,
12,
382,
278,
1887,
5199,
13,
288,
3639,
309,
12,
10358,
422,
446,
13,
327,
446,
31,
3639,
6674,
2393,
33,
2704,
6674,
5621,
3639,
309,
12,
10828,
67,
14926,
13,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
514,
19276,
12,
382,
278,
1887,
5199,
13,
288,
3639,
309,
12,
10358,
422,
446,
13,
327,
446,
31,
3639,
6674,
2393,
33,
2704,
6674,
5621,
3639,
309,
12,
10828,
67,
14926,
13,
... |
"BnN"); | "Bn"); | public void test_doStep_predicates_propertyOwner(){ // missingProperty[@name=foo] testNullPointer("/foo[@name='foo']", "/foo[@name='foo']", "BnNnN"); // missingProperty[index] testNullPointer("/foo[3]", "/foo[3]", "BnN"); } | 52531 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52531/430fdd01e75a5e681274aa65adeb2d9826ee45a8/SimplePathInterpreterTest.java/buggy/src/test/org/apache/commons/jxpath/ri/axes/SimplePathInterpreterTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
67,
2896,
4160,
67,
6510,
8242,
67,
4468,
5541,
1435,
95,
3639,
368,
3315,
1396,
14782,
529,
33,
11351,
65,
3639,
1842,
2041,
4926,
2932,
19,
11351,
14782,
529,
2218,
113... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
67,
2896,
4160,
67,
6510,
8242,
67,
4468,
5541,
1435,
95,
3639,
368,
3315,
1396,
14782,
529,
33,
11351,
65,
3639,
1842,
2041,
4926,
2932,
19,
11351,
14782,
529,
2218,
113... |
getBody().run( context, output); | invokeBody( output); | public void firePreGoal(Goal goal) throws Exception { // lets run the body log.debug( "Running pre goal: " + getName() ); getBody().run( context, output); } | 51800 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51800/0d5aec147baa5b0b5399591c7e9dd775bb22bcb4/PreGoalTag.java/buggy/src/java/org/apache/commons/jelly/tags/werkz/PreGoalTag.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1171,
1071,
918,
4452,
1386,
27716,
12,
27716,
17683,
13,
1216,
1185,
288,
10792,
368,
14557,
1086,
326,
1417,
10792,
613,
18,
4148,
12,
315,
7051,
675,
17683,
30,
315,
397,
1723,
1435,
11272,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1171,
1071,
918,
4452,
1386,
27716,
12,
27716,
17683,
13,
1216,
1185,
288,
10792,
368,
14557,
1086,
326,
1417,
10792,
613,
18,
4148,
12,
315,
7051,
675,
17683,
30,
315,
397,
1723,
1435,
11272,
... |
stack[stackTop] = stack[VAR_SHFT + slot]; sDbl[stackTop] = sDbl[VAR_SHFT + slot]; | if (!useActivationVars) { stack[stackTop] = stack[VAR_SHFT + slot]; sDbl[stackTop] = sDbl[VAR_SHFT + slot]; }else { stack[stackTop] = activationGet(fnOrScript, scope, slot); } | public static Object interpret(Context cx, Scriptable scope, Scriptable thisObj, Object[] args, NativeFunction fnOrScript, InterpreterData theData) throws JavaScriptException { if (cx.interpreterSecurityDomain != theData.securityDomain) { // If securityDomain is different, update domain in Cotext // and call self under new domain Object savedDomain = cx.interpreterSecurityDomain; cx.interpreterSecurityDomain = theData.securityDomain; try { return interpret(cx, scope, thisObj, args, fnOrScript, theData); } finally { cx.interpreterSecurityDomain = savedDomain; } } final Object DBL_MRK = Interpreter.DBL_MRK; final Scriptable undefined = Undefined.instance; final int VAR_SHFT = 0; final int maxVars = theData.itsMaxVars; final int LOCAL_SHFT = VAR_SHFT + maxVars; final int TRY_STACK_SHFT = LOCAL_SHFT + theData.itsMaxLocals; final int STACK_SHFT = TRY_STACK_SHFT + theData.itsMaxTryDepth;// stack[VAR_SHFT <= i < LOCAL_SHFT]: variables// stack[LOCAL_SHFT <= i < TRY_STACK_SHFT]: used for newtemp/usetemp// stack[TRY_STACK_SHFT <= i < STACK_SHFT]: stack of try scopes// stack[STACK_SHFT <= i < STACK_SHFT + theData.itsMaxStack]: stack data// sDbl[TRY_STACK_SHFT <= i < STACK_SHFT]: stack of try block pc, stored as doubles// sDbl[any other i]: if stack[i] is DBL_MRK, sDbl[i] holds the number value int maxFrameArray = theData.itsMaxFrameArray; if (maxFrameArray != STACK_SHFT + theData.itsMaxStack) Context.codeBug(); Object[] stack = new Object[maxFrameArray]; double[] sDbl = new double[maxFrameArray]; int stackTop = STACK_SHFT - 1; int tryStackTop = 0; // add TRY_STACK_SHFT to get real index int definedArgs = fnOrScript.argCount; if (definedArgs != 0) { if (definedArgs > args.length) { definedArgs = args.length; } for (int i = 0; i != definedArgs; ++i) { stack[VAR_SHFT + i] = args[i]; } } for (int i = definedArgs; i != maxVars; ++i) { stack[VAR_SHFT + i] = undefined; } if (theData.itsFunctionType != 0) { if (fnOrScript.itsClosure != null) { scope = fnOrScript.itsClosure; }else if (!theData.itsUseDynamicScope) { scope = fnOrScript.getParentScope(); } if (theData.itsCheckThis) { thisObj = ScriptRuntime.getThis(thisObj); } if (theData.itsNeedsActivation) { scope = ScriptRuntime.initVarObj(cx, scope, fnOrScript, thisObj, args); } } else { scope = ScriptRuntime.initScript(cx, scope, fnOrScript, thisObj, theData.itsFromEvalCode); } if (theData.itsNestedFunctions != null) { if (theData.itsFunctionType != 0 && !theData.itsNeedsActivation) Context.codeBug(); for (int i = 0; i < theData.itsNestedFunctions.length; i++) createFunctionObject(theData.itsNestedFunctions[i], scope, theData.itsFromEvalCode); } DebugFrame frame = null; if (cx.debugger != null) { frame = cx.debugger.enterFrame(cx, scope, thisObj, args, (DebuggableScript)fnOrScript); } Object result = undefined; byte[] iCode = theData.itsICode; String[] strings = theData.itsStringTable; int pc = 0; int pcPrevBranch = pc; final int instructionThreshold = cx.instructionThreshold; // During function call this will be set to -1 so catch can properly // adjust it int instructionCount = cx.instructionCount; // arbitrary number to add to instructionCount when calling // other functions final int INVOCATION_COST = 100; Loop: while (true) { try { switch (iCode[pc] & 0xff) { case TokenStream.ENDTRY : tryStackTop--; break; case TokenStream.TRY : stack[TRY_STACK_SHFT + tryStackTop] = scope; sDbl[TRY_STACK_SHFT + tryStackTop] = (double)pc; ++tryStackTop; // Skip starting pc of catch/finally blocks pc += 4; break; case TokenStream.GE : { --stackTop; Object rhs = stack[stackTop + 1]; Object lhs = stack[stackTop]; boolean valBln; if (rhs == DBL_MRK || lhs == DBL_MRK) { double rDbl = stack_double(stack, sDbl, stackTop + 1); double lDbl = stack_double(stack, sDbl, stackTop); valBln = (rDbl == rDbl && lDbl == lDbl && rDbl <= lDbl); } else { valBln = (1 == ScriptRuntime.cmp_LE(rhs, lhs)); } stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.LE : { --stackTop; Object rhs = stack[stackTop + 1]; Object lhs = stack[stackTop]; boolean valBln; if (rhs == DBL_MRK || lhs == DBL_MRK) { double rDbl = stack_double(stack, sDbl, stackTop + 1); double lDbl = stack_double(stack, sDbl, stackTop); valBln = (rDbl == rDbl && lDbl == lDbl && lDbl <= rDbl); } else { valBln = (1 == ScriptRuntime.cmp_LE(lhs, rhs)); } stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.GT : { --stackTop; Object rhs = stack[stackTop + 1]; Object lhs = stack[stackTop]; boolean valBln; if (rhs == DBL_MRK || lhs == DBL_MRK) { double rDbl = stack_double(stack, sDbl, stackTop + 1); double lDbl = stack_double(stack, sDbl, stackTop); valBln = (rDbl == rDbl && lDbl == lDbl && rDbl < lDbl); } else { valBln = (1 == ScriptRuntime.cmp_LT(rhs, lhs)); } stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.LT : { --stackTop; Object rhs = stack[stackTop + 1]; Object lhs = stack[stackTop]; boolean valBln; if (rhs == DBL_MRK || lhs == DBL_MRK) { double rDbl = stack_double(stack, sDbl, stackTop + 1); double lDbl = stack_double(stack, sDbl, stackTop); valBln = (rDbl == rDbl && lDbl == lDbl && lDbl < rDbl); } else { valBln = (1 == ScriptRuntime.cmp_LT(lhs, rhs)); } stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.IN : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); boolean valBln = ScriptRuntime.in(lhs, rhs, scope); stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.INSTANCEOF : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); boolean valBln = ScriptRuntime.instanceOf(scope, lhs, rhs); stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.EQ : { --stackTop; boolean valBln = do_eq(stack, sDbl, stackTop); stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.NE : { --stackTop; boolean valBln = !do_eq(stack, sDbl, stackTop); stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.SHEQ : { --stackTop; boolean valBln = do_sheq(stack, sDbl, stackTop); stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.SHNE : { --stackTop; boolean valBln = !do_sheq(stack, sDbl, stackTop); stack[stackTop] = valBln ? Boolean.TRUE : Boolean.FALSE; break; } case TokenStream.IFNE : { Object val = stack[stackTop]; boolean valBln; if (val != DBL_MRK) { valBln = !ScriptRuntime.toBoolean(val); } else { double valDbl = sDbl[stackTop]; valBln = !(valDbl == valDbl && valDbl != 0.0); } --stackTop; if (valBln) { if (instructionThreshold != 0) { instructionCount += pc + 3 - pcPrevBranch; if (instructionCount > instructionThreshold) { cx.observeInstructionCount (instructionCount); instructionCount = 0; } } pcPrevBranch = pc = getTarget(iCode, pc + 1); continue; } pc += 2; break; } case TokenStream.IFEQ : { boolean valBln; Object val = stack[stackTop]; if (val != DBL_MRK) { valBln = ScriptRuntime.toBoolean(val); } else { double valDbl = sDbl[stackTop]; valBln = (valDbl == valDbl && valDbl != 0.0); } --stackTop; if (valBln) { if (instructionThreshold != 0) { instructionCount += pc + 3 - pcPrevBranch; if (instructionCount > instructionThreshold) { cx.observeInstructionCount (instructionCount); instructionCount = 0; } } pcPrevBranch = pc = getTarget(iCode, pc + 1); continue; } pc += 2; break; } case TokenStream.GOTO : if (instructionThreshold != 0) { instructionCount += pc + 3 - pcPrevBranch; if (instructionCount > instructionThreshold) { cx.observeInstructionCount(instructionCount); instructionCount = 0; } } pcPrevBranch = pc = getTarget(iCode, pc + 1); continue; case TokenStream.GOSUB : sDbl[++stackTop] = pc + 3; if (instructionThreshold != 0) { instructionCount += pc + 3 - pcPrevBranch; if (instructionCount > instructionThreshold) { cx.observeInstructionCount(instructionCount); instructionCount = 0; } } pcPrevBranch = pc = getTarget(iCode, pc + 1); continue; case TokenStream.RETSUB : { int slot = (iCode[pc + 1] & 0xFF); if (instructionThreshold != 0) { instructionCount += pc + 2 - pcPrevBranch; if (instructionCount > instructionThreshold) { cx.observeInstructionCount(instructionCount); instructionCount = 0; } } pcPrevBranch = pc = (int)sDbl[LOCAL_SHFT + slot]; continue; } case TokenStream.POP : stackTop--; break; case TokenStream.DUP : stack[stackTop + 1] = stack[stackTop]; sDbl[stackTop + 1] = sDbl[stackTop]; stackTop++; break; case TokenStream.POPV : result = stack[stackTop]; if (result == DBL_MRK) result = doubleWrap(sDbl[stackTop]); --stackTop; break; case TokenStream.RETURN : result = stack[stackTop]; if (result == DBL_MRK) result = doubleWrap(sDbl[stackTop]); --stackTop; break Loop; case RETURN_UNDEF_ICODE : result = undefined; break Loop; case END_ICODE: break Loop; case TokenStream.BITNOT : { int rIntValue = stack_int32(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = ~rIntValue; break; } case TokenStream.BITAND : { int rIntValue = stack_int32(stack, sDbl, stackTop); --stackTop; int lIntValue = stack_int32(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lIntValue & rIntValue; break; } case TokenStream.BITOR : { int rIntValue = stack_int32(stack, sDbl, stackTop); --stackTop; int lIntValue = stack_int32(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lIntValue | rIntValue; break; } case TokenStream.BITXOR : { int rIntValue = stack_int32(stack, sDbl, stackTop); --stackTop; int lIntValue = stack_int32(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lIntValue ^ rIntValue; break; } case TokenStream.LSH : { int rIntValue = stack_int32(stack, sDbl, stackTop); --stackTop; int lIntValue = stack_int32(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lIntValue << rIntValue; break; } case TokenStream.RSH : { int rIntValue = stack_int32(stack, sDbl, stackTop); --stackTop; int lIntValue = stack_int32(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lIntValue >> rIntValue; break; } case TokenStream.URSH : { int rIntValue = stack_int32(stack, sDbl, stackTop) & 0x1F; --stackTop; double lDbl = stack_double(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = ScriptRuntime.toUint32(lDbl) >>> rIntValue; break; } case TokenStream.ADD : --stackTop; do_add(stack, sDbl, stackTop); break; case TokenStream.SUB : { double rDbl = stack_double(stack, sDbl, stackTop); --stackTop; double lDbl = stack_double(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lDbl - rDbl; break; } case TokenStream.NEG : { double rDbl = stack_double(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = -rDbl; break; } case TokenStream.POS : { double rDbl = stack_double(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = rDbl; break; } case TokenStream.MUL : { double rDbl = stack_double(stack, sDbl, stackTop); --stackTop; double lDbl = stack_double(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lDbl * rDbl; break; } case TokenStream.DIV : { double rDbl = stack_double(stack, sDbl, stackTop); --stackTop; double lDbl = stack_double(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; // Detect the divide by zero or let Java do it ? sDbl[stackTop] = lDbl / rDbl; break; } case TokenStream.MOD : { double rDbl = stack_double(stack, sDbl, stackTop); --stackTop; double lDbl = stack_double(stack, sDbl, stackTop); stack[stackTop] = DBL_MRK; sDbl[stackTop] = lDbl % rDbl; break; } case TokenStream.BINDNAME : { String name = strings[getShort(iCode, pc + 1)]; stack[++stackTop] = ScriptRuntime.bind(scope, name); pc += 2; break; } case TokenStream.GETBASE : { String name = strings[getShort(iCode, pc + 1)]; stack[++stackTop] = ScriptRuntime.getBase(scope, name); pc += 2; break; } case TokenStream.SETNAME : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; // what about class cast exception here for lhs? stack[stackTop] = ScriptRuntime.setName ((Scriptable)lhs, rhs, scope, strings[getShort(iCode, pc + 1)]); pc += 2; break; } case TokenStream.DELPROP : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.delete(lhs, rhs); break; } case TokenStream.GETPROP : { String name = (String)stack[stackTop]; --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.getProp(lhs, name, scope); break; } case TokenStream.SETPROP : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; String name = (String)stack[stackTop]; --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.setProp(lhs, name, rhs, scope); break; } case TokenStream.GETELEM : do_getElem(cx, stack, sDbl, stackTop, scope); --stackTop; break; case TokenStream.SETELEM : do_setElem(cx, stack, sDbl, stackTop, scope); stackTop -= 2; break; case TokenStream.PROPINC : { String name = (String)stack[stackTop]; --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.postIncrement(lhs, name, scope); break; } case TokenStream.PROPDEC : { String name = (String)stack[stackTop]; --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.postDecrement(lhs, name, scope); break; } case TokenStream.ELEMINC : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.postIncrementElem(lhs, rhs, scope); break; } case TokenStream.ELEMDEC : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.postDecrementElem(lhs, rhs, scope); break; } case TokenStream.GETTHIS : { Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.getThis((Scriptable)lhs); break; } case TokenStream.NEWTEMP : { int slot = (iCode[++pc] & 0xFF); stack[LOCAL_SHFT + slot] = stack[stackTop]; sDbl[LOCAL_SHFT + slot] = sDbl[stackTop]; break; } case TokenStream.USETEMP : { int slot = (iCode[++pc] & 0xFF); ++stackTop; stack[stackTop] = stack[LOCAL_SHFT + slot]; sDbl[stackTop] = sDbl[LOCAL_SHFT + slot]; break; } case TokenStream.CALLSPECIAL : { if (instructionThreshold != 0) { instructionCount += INVOCATION_COST; cx.instructionCount = instructionCount; instructionCount = -1; } int lineNum = getShort(iCode, pc + 1); String name = strings[getShort(iCode, pc + 3)]; int count = getShort(iCode, pc + 5); Object[] outArgs = getArgsArray(stack, sDbl, stackTop, count); stackTop -= count; Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.callSpecial( cx, lhs, rhs, outArgs, thisObj, scope, name, lineNum); pc += 6; instructionCount = cx.instructionCount; break; } case TokenStream.CALL : { if (instructionThreshold != 0) { instructionCount += INVOCATION_COST; cx.instructionCount = instructionCount; instructionCount = -1; } cx.instructionCount = instructionCount; int count = getShort(iCode, pc + 3); Object[] outArgs = getArgsArray(stack, sDbl, stackTop, count); stackTop -= count; Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); if (lhs == undefined) { int i = getShort(iCode, pc + 1); if (i != -1) lhs = strings[i]; } Scriptable calleeScope = scope; if (theData.itsNeedsActivation) { calleeScope = ScriptableObject. getTopLevelScope(scope); } stack[stackTop] = ScriptRuntime.call(cx, lhs, rhs, outArgs, calleeScope); pc += 4; instructionCount = cx.instructionCount; break; } case TokenStream.NEW : { if (instructionThreshold != 0) { instructionCount += INVOCATION_COST; cx.instructionCount = instructionCount; instructionCount = -1; } int count = getShort(iCode, pc + 3); Object[] outArgs = getArgsArray(stack, sDbl, stackTop, count); stackTop -= count; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); if (lhs == undefined && getShort(iCode, pc + 1) != -1) { // special code for better error message for call // to undefined lhs = strings[getShort(iCode, pc + 1)]; } stack[stackTop] = ScriptRuntime.newObject(cx, lhs, outArgs, scope); pc += 4; instructionCount = cx.instructionCount; break; } case TokenStream.TYPEOF : { Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.typeof(lhs); break; } case TokenStream.TYPEOFNAME : { String name = strings[getShort(iCode, pc + 1)]; stack[++stackTop] = ScriptRuntime.typeofName(scope, name); pc += 2; break; } case TokenStream.STRING : stack[++stackTop] = strings[getShort(iCode, pc + 1)]; pc += 2; break; case SHORTNUMBER_ICODE : ++stackTop; stack[stackTop] = DBL_MRK; sDbl[stackTop] = getShort(iCode, pc + 1); pc += 2; break; case INTNUMBER_ICODE : ++stackTop; stack[stackTop] = DBL_MRK; sDbl[stackTop] = getInt(iCode, pc + 1); pc += 4; break; case TokenStream.NUMBER : ++stackTop; stack[stackTop] = DBL_MRK; sDbl[stackTop] = theData. itsDoubleTable[getShort(iCode, pc + 1)]; pc += 2; break; case TokenStream.NAME : stack[++stackTop] = ScriptRuntime.name (scope, strings[getShort(iCode, pc + 1)]); pc += 2; break; case TokenStream.NAMEINC : stack[++stackTop] = ScriptRuntime.postIncrement (scope, strings[getShort(iCode, pc + 1)]); pc += 2; break; case TokenStream.NAMEDEC : stack[++stackTop] = ScriptRuntime.postDecrement (scope, strings[getShort(iCode, pc + 1)]); pc += 2; break; case TokenStream.SETVAR : { int slot = (iCode[++pc] & 0xFF); stack[VAR_SHFT + slot] = stack[stackTop]; sDbl[VAR_SHFT + slot] = sDbl[stackTop]; break; } case TokenStream.GETVAR : { int slot = (iCode[++pc] & 0xFF); ++stackTop; stack[stackTop] = stack[VAR_SHFT + slot]; sDbl[stackTop] = sDbl[VAR_SHFT + slot]; break; } case TokenStream.VARINC : { int slot = (iCode[++pc] & 0xFF); ++stackTop; stack[stackTop] = stack[VAR_SHFT + slot]; sDbl[stackTop] = sDbl[VAR_SHFT + slot]; stack[VAR_SHFT + slot] = DBL_MRK; sDbl[VAR_SHFT + slot] = stack_double(stack, sDbl, stackTop) + 1.0; break; } case TokenStream.VARDEC : { int slot = (iCode[++pc] & 0xFF); ++stackTop; stack[stackTop] = stack[VAR_SHFT + slot]; sDbl[stackTop] = sDbl[VAR_SHFT + slot]; stack[VAR_SHFT + slot] = DBL_MRK; sDbl[VAR_SHFT + slot] = stack_double(stack, sDbl, stackTop) - 1.0; break; } case TokenStream.ZERO : ++stackTop; stack[stackTop] = DBL_MRK; sDbl[stackTop] = 0; break; case TokenStream.ONE : ++stackTop; stack[stackTop] = DBL_MRK; sDbl[stackTop] = 1; break; case TokenStream.NULL : stack[++stackTop] = null; break; case TokenStream.THIS : stack[++stackTop] = thisObj; break; case TokenStream.THISFN : stack[++stackTop] = fnOrScript; break; case TokenStream.FALSE : stack[++stackTop] = Boolean.FALSE; break; case TokenStream.TRUE : stack[++stackTop] = Boolean.TRUE; break; case TokenStream.UNDEFINED : stack[++stackTop] = Undefined.instance; break; case TokenStream.THROW : { Object exception = stack[stackTop]; if (exception == DBL_MRK) exception = doubleWrap(sDbl[stackTop]); --stackTop; throw new JavaScriptException(exception); } case TokenStream.JTHROW : { Object exception = stack[stackTop]; // No need to check for DBL_MRK: exception must be Exception --stackTop; if (exception instanceof JavaScriptException) throw (JavaScriptException)exception; else throw (RuntimeException)exception; } case TokenStream.ENTERWITH : { Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); --stackTop; scope = ScriptRuntime.enterWith(lhs, scope); break; } case TokenStream.LEAVEWITH : scope = ScriptRuntime.leaveWith(scope); break; case TokenStream.NEWSCOPE : stack[++stackTop] = ScriptRuntime.newScope(); break; case TokenStream.ENUMINIT : { int slot = (iCode[++pc] & 0xFF); Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); --stackTop; stack[LOCAL_SHFT + slot] = ScriptRuntime.initEnum(lhs, scope); break; } case TokenStream.ENUMNEXT : { int slot = (iCode[++pc] & 0xFF); Object val = stack[LOCAL_SHFT + slot]; ++stackTop; stack[stackTop] = ScriptRuntime. nextEnum((Enumeration)val); break; } case TokenStream.GETPROTO : { Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.getProto(lhs, scope); break; } case TokenStream.GETPARENT : { Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.getParent(lhs); break; } case TokenStream.GETSCOPEPARENT : { Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.getParent(lhs, scope); break; } case TokenStream.SETPROTO : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.setProto(lhs, rhs, scope); break; } case TokenStream.SETPARENT : { Object rhs = stack[stackTop]; if (rhs == DBL_MRK) rhs = doubleWrap(sDbl[stackTop]); --stackTop; Object lhs = stack[stackTop]; if (lhs == DBL_MRK) lhs = doubleWrap(sDbl[stackTop]); stack[stackTop] = ScriptRuntime.setParent(lhs, rhs, scope); break; } case TokenStream.SCOPE : stack[++stackTop] = scope; break; case TokenStream.CLOSURE : { int i = getShort(iCode, pc + 1); stack[++stackTop] = new InterpretedFunction( theData.itsNestedFunctions[i], scope, cx); createFunctionObject( (InterpretedFunction)stack[stackTop], scope, theData.itsFromEvalCode); pc += 2; break; } case TokenStream.OBJECT : { int i = getShort(iCode, pc + 1); stack[++stackTop] = theData.itsRegExpLiterals[i]; pc += 2; break; } case SOURCEFILE_ICODE : cx.interpreterSourceFile = theData.itsSourceFile; break; case LINE_ICODE : case BREAKPOINT_ICODE : { int line = getShort(iCode, pc + 1); cx.interpreterLine = line; if (frame != null) { boolean breakpoint = ((iCode[pc] & 0xff) == BREAKPOINT_ICODE); frame.onLineChange(cx, line, breakpoint); } pc += 2; break; } default : dumpICode(theData); throw new RuntimeException("Unknown icode : " + (iCode[pc] & 0xff) + " @ pc : " + pc); } pc++; } catch (Throwable ex) { if (instructionThreshold != 0) { if (instructionCount < 0) { // throw during function call instructionCount = cx.instructionCount; } else { // throw during any other operation instructionCount += pc - pcPrevBranch; cx.instructionCount = instructionCount; } } final int SCRIPT_THROW = 0, ECMA = 1, RUNTIME = 2, OTHER = 3; int exType; Object catchObj = ex; // Object seen by script catch for (;;) { if (catchObj instanceof JavaScriptException) { catchObj = ScriptRuntime.unwrapJavaScriptException ((JavaScriptException)catchObj); exType = SCRIPT_THROW; } else if (catchObj instanceof EcmaError) { // an offical ECMA error object, catchObj = ((EcmaError)catchObj).getErrorObject(); exType = ECMA; } else if (catchObj instanceof RuntimeException) { if (catchObj instanceof WrappedException) { Object w = ((WrappedException) catchObj).unwrap(); if (w instanceof Throwable) { catchObj = (Throwable) w; continue; } } catchObj = null; // script can not catch this exType = RUNTIME; } else { // Error instance catchObj = null; // script can not catch this exType = OTHER; } break; } if (exType != OTHER && frame != null) { frame.onExceptionThrown(cx, ex); } boolean rethrow = true; if (exType != OTHER && tryStackTop > 0) { // Do not allow for JS to interfere with Error instances // (exType == OTHER), as they can be used to terminate // long running script --tryStackTop; int try_pc = (int)sDbl[TRY_STACK_SHFT + tryStackTop]; if (exType == SCRIPT_THROW || exType == ECMA) { // Allow JS to catch only JavaScriptException and // EcmaError int catch_pc = getTarget(iCode, try_pc + 1); if (catch_pc == try_pc) { catch_pc = 0; } if (catch_pc != 0) { // Has catch block rethrow = false; pc = catch_pc; stackTop = STACK_SHFT; stack[stackTop] = catchObj; } } if (rethrow) { int finally_pc = getTarget(iCode, try_pc + 3); if (finally_pc == try_pc + 2) { finally_pc = 0; } if (finally_pc != 0) { // has finally block rethrow = false; pc = finally_pc; stackTop = STACK_SHFT; stack[stackTop] = ex; } } } if (rethrow) { if (frame != null) { frame.onExit(cx, true, ex); } if (theData.itsNeedsActivation) { ScriptRuntime.popActivation(cx); } if (exType == SCRIPT_THROW) throw (JavaScriptException)ex; if (exType == ECMA || exType == RUNTIME) throw (RuntimeException)ex; throw (Error)ex; } // We caught an exception, // Notify instruction observer if necessary // and point pcPrevBranch to start of catch/finally block if (instructionThreshold != 0) { if (instructionCount > instructionThreshold) { // Note: this can throw Error cx.observeInstructionCount(instructionCount); instructionCount = 0; } } pcPrevBranch = pc; // restore scope at try point scope = (Scriptable)stack[TRY_STACK_SHFT + tryStackTop]; } } if (frame != null) { frame.onExit(cx, false, result); } if (theData.itsNeedsActivation) { ScriptRuntime.popActivation(cx); } if (instructionThreshold != 0) { if (instructionCount > instructionThreshold) { cx.observeInstructionCount(instructionCount); instructionCount = 0; } cx.instructionCount = instructionCount; } return result; } | 47609 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47609/394848a46d862bd7719dc217f350c955f2df2594/Interpreter.java/clean/js/rhino/src/org/mozilla/javascript/Interpreter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1033,
10634,
12,
1042,
9494,
16,
22780,
2146,
16,
4766,
282,
22780,
15261,
16,
1033,
8526,
833,
16,
4766,
282,
16717,
2083,
2295,
1162,
3651,
16,
4766,
282,
5294,
11599,
751,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
1033,
10634,
12,
1042,
9494,
16,
22780,
2146,
16,
4766,
282,
22780,
15261,
16,
1033,
8526,
833,
16,
4766,
282,
16717,
2083,
2295,
1162,
3651,
16,
4766,
282,
5294,
11599,
751,
3... |
controlContentAdapter.setControlContents(control, text); | controlContentAdapter.setControlContents(control, text, cursorPosition); | private void setControlContent(String text) { if (isValid()) controlContentAdapter.setControlContents(control, text); } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/54f5816382677a87ac1d149868af2370808e4f06/ContentProposalAdapter.java/clean/bundles/org.eclipse.jface/src/org/eclipse/jface/fieldassist/ContentProposalAdapter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
444,
3367,
1350,
12,
780,
977,
13,
288,
202,
202,
430,
261,
26810,
10756,
1082,
202,
7098,
1350,
4216,
18,
542,
3367,
6323,
12,
7098,
16,
977,
1769,
202,
97,
2,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
444,
3367,
1350,
12,
780,
977,
13,
288,
202,
202,
430,
261,
26810,
10756,
1082,
202,
7098,
1350,
4216,
18,
542,
3367,
6323,
12,
7098,
16,
977,
1769,
202,
97,
2,
-100,
... |
} catch (IOException ioe) { _log.error("Error reporting abuse", ioe); | public void runJob() { if (_runner.isDead()) return; AbuseReason res = new AbuseReason(); res.setReason(_reason); AbuseSeverity sev = new AbuseSeverity(); sev.setSeverity(_severity); ReportAbuseMessage msg = new ReportAbuseMessage(); msg.setMessageId(null); msg.setReason(res); msg.setSessionId(_runner.getSessionId()); msg.setSeverity(sev); try { _runner.doSend(msg); } catch (I2CPMessageException ime) { _log.error("Error reporting abuse", ime); } catch (IOException ioe) { _log.error("Error reporting abuse", ioe); } } | 45677 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45677/14b9f9509fb68b2e019bd0b2eba7ed801fd81d87/ReportAbuseJob.java/buggy/router/java/src/net/i2p/router/client/ReportAbuseJob.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1086,
2278,
1435,
288,
3639,
309,
261,
67,
18156,
18,
291,
11852,
10756,
327,
31,
3639,
9771,
1202,
8385,
400,
273,
394,
9771,
1202,
8385,
5621,
3639,
400,
18,
542,
8385,
24899... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1086,
2278,
1435,
288,
3639,
309,
261,
67,
18156,
18,
291,
11852,
10756,
327,
31,
3639,
9771,
1202,
8385,
400,
273,
394,
9771,
1202,
8385,
5621,
3639,
400,
18,
542,
8385,
24899... | |
org.exist.xquery.parser.XQueryAST tmp46_AST_in = (org.exist.xquery.parser.XQueryAST)_t; | org.exist.xquery.parser.XQueryAST tmp47_AST_in = (org.exist.xquery.parser.XQueryAST)_t; | public final void sequenceType(AST _t, SequenceType type ) throws RecognitionException, XPathException { org.exist.xquery.parser.XQueryAST sequenceType_AST_in = (_t == ASTNULL) ? null : (org.exist.xquery.parser.XQueryAST)_t; org.exist.xquery.parser.XQueryAST t = null; org.exist.xquery.parser.XQueryAST qn1 = null; org.exist.xquery.parser.XQueryAST qn2 = null; { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case ATOMIC_TYPE: { AST __t45 = _t; t = _t==ASTNULL ? null :(org.exist.xquery.parser.XQueryAST)_t; match(_t,ATOMIC_TYPE); _t = _t.getFirstChild(); QName qn= QName.parse(context, t.getText()); int code= Type.getType(qn); if(!Type.subTypeOf(code, Type.ATOMIC)) throw new XPathException(t, "Type " + qn.toString() + " is not an atomic type"); type.setPrimaryType(code); _t = __t45; _t = _t.getNextSibling(); break; } case LITERAL_empty: { AST __t46 = _t; org.exist.xquery.parser.XQueryAST tmp39_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,LITERAL_empty); _t = _t.getFirstChild(); type.setPrimaryType(Type.EMPTY); type.setCardinality(Cardinality.EMPTY); _t = __t46; _t = _t.getNextSibling(); break; } case LITERAL_item: { AST __t47 = _t; org.exist.xquery.parser.XQueryAST tmp40_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,LITERAL_item); _t = _t.getFirstChild(); type.setPrimaryType(Type.ITEM); _t = __t47; _t = _t.getNextSibling(); break; } case LITERAL_node: { AST __t48 = _t; org.exist.xquery.parser.XQueryAST tmp41_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,LITERAL_node); _t = _t.getFirstChild(); type.setPrimaryType(Type.NODE); _t = __t48; _t = _t.getNextSibling(); break; } case LITERAL_element: { AST __t49 = _t; org.exist.xquery.parser.XQueryAST tmp42_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,LITERAL_element); _t = _t.getFirstChild(); type.setPrimaryType(Type.ELEMENT); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case WILDCARD: { org.exist.xquery.parser.XQueryAST tmp43_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,WILDCARD); _t = _t.getNextSibling(); break; } case QNAME: { qn1 = (org.exist.xquery.parser.XQueryAST)_t; match(_t,QNAME); _t = _t.getNextSibling(); QName qname= QName.parse(context, qn1.getText()); type.setNodeName(qname); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case QNAME: { org.exist.xquery.parser.XQueryAST tmp44_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,QNAME); _t = _t.getNextSibling(); throwException(qn1, "Tests of the form element(QName, TypeName) are not supported!"); break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } _t = __t49; _t = _t.getNextSibling(); break; } case ATTRIBUTE_TEST: { AST __t52 = _t; org.exist.xquery.parser.XQueryAST tmp45_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,ATTRIBUTE_TEST); _t = _t.getFirstChild(); type.setPrimaryType(Type.ATTRIBUTE); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case WILDCARD: { org.exist.xquery.parser.XQueryAST tmp46_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,WILDCARD); _t = _t.getNextSibling(); break; } case QNAME: { qn2 = (org.exist.xquery.parser.XQueryAST)_t; match(_t,QNAME); _t = _t.getNextSibling(); QName qname= QName.parse(context, qn2.getText()); type.setNodeName(qname); { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case QNAME: { org.exist.xquery.parser.XQueryAST tmp47_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,QNAME); _t = _t.getNextSibling(); throwException(qn1, "Tests of the form attribute(QName, TypeName) are not supported!"); break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } _t = __t52; _t = _t.getNextSibling(); break; } case LITERAL_text: { AST __t55 = _t; org.exist.xquery.parser.XQueryAST tmp48_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,LITERAL_text); _t = _t.getFirstChild(); type.setPrimaryType(Type.TEXT); _t = __t55; _t = _t.getNextSibling(); break; } case 141: { AST __t56 = _t; org.exist.xquery.parser.XQueryAST tmp49_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,141); _t = _t.getFirstChild(); type.setPrimaryType(Type.PROCESSING_INSTRUCTION); _t = __t56; _t = _t.getNextSibling(); break; } case LITERAL_comment: { AST __t57 = _t; org.exist.xquery.parser.XQueryAST tmp50_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,LITERAL_comment); _t = _t.getFirstChild(); type.setPrimaryType(Type.COMMENT); _t = __t57; _t = _t.getNextSibling(); break; } case 142: { AST __t58 = _t; org.exist.xquery.parser.XQueryAST tmp51_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,142); _t = _t.getFirstChild(); type.setPrimaryType(Type.DOCUMENT); _t = __t58; _t = _t.getNextSibling(); break; } default: { throw new NoViableAltException(_t); } } } { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case STAR: { org.exist.xquery.parser.XQueryAST tmp52_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,STAR); _t = _t.getNextSibling(); type.setCardinality(Cardinality.ZERO_OR_MORE); break; } case PLUS: { org.exist.xquery.parser.XQueryAST tmp53_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,PLUS); _t = _t.getNextSibling(); type.setCardinality(Cardinality.ONE_OR_MORE); break; } case QUESTION: { org.exist.xquery.parser.XQueryAST tmp54_AST_in = (org.exist.xquery.parser.XQueryAST)_t; match(_t,QUESTION); _t = _t.getNextSibling(); type.setCardinality(Cardinality.ZERO_OR_ONE); break; } case 3: { break; } default: { throw new NoViableAltException(_t); } } } _retTree = _t; } | 2909 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/2909/10544e5ec103a411822c6180ed81ef38eab15de8/XQueryTreeParser.java/buggy/src/org/exist/xquery/parser/XQueryTreeParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
3102,
559,
12,
9053,
389,
88,
16,
202,
202,
4021,
559,
618,
202,
13,
1216,
9539,
16,
10172,
503,
288,
9506,
202,
3341,
18,
7398,
18,
92,
2271,
18,
4288,
18,
60,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3102,
559,
12,
9053,
389,
88,
16,
202,
202,
4021,
559,
618,
202,
13,
1216,
9539,
16,
10172,
503,
288,
9506,
202,
3341,
18,
7398,
18,
92,
2271,
18,
4288,
18,
60,
... |
int mask; switch (vk) { case KeyEvent.VK_ALT : mask = InputEvent.ALT_DOWN_MASK; break; case KeyEvent.VK_ALT_GRAPH : mask = InputEvent.ALT_GRAPH_DOWN_MASK; break; case KeyEvent.VK_CONTROL : mask = InputEvent.CTRL_DOWN_MASK; break; case KeyEvent.VK_SHIFT : mask = InputEvent.SHIFT_DOWN_MASK; break; default : mask = 0; } if (mask != 0) { if (released) { flags &= ~mask; } else { flags |= mask; } } | adjustFlags(vk, released); | public KeyboardEvent interpretScancode(int scancode) { if (scancode == XT_EXTENDED) { lastScancode = scancode; return null; } boolean released = ((scancode & XT_RELEASE) != 0); scancode &= 0x7f; int vk = deriveKeyCode(scancode, (lastScancode == XT_EXTENDED)); // debug output to find new keycodes// System.err.println("[" + (lastScancode == XT_EXTENDED ? "E" : "N") + scancode + "] " /*+ KeyEvent.getKeyText(vk)*/); int mask; switch (vk) { case KeyEvent.VK_ALT : mask = InputEvent.ALT_DOWN_MASK; break; case KeyEvent.VK_ALT_GRAPH : mask = InputEvent.ALT_GRAPH_DOWN_MASK; break; case KeyEvent.VK_CONTROL : mask = InputEvent.CTRL_DOWN_MASK; break; case KeyEvent.VK_SHIFT : mask = InputEvent.SHIFT_DOWN_MASK; break; default : mask = 0; } if (mask != 0) { if (released) { flags &= ~mask; } else { flags |= mask; } } if (vk != 0) { char ch; try { ch = interpretExtendedScanCode(scancode, vk, released); long time = System.currentTimeMillis(); lastScancode = scancode; return new KeyboardEvent(released ? KeyEvent.KEY_RELEASED : KeyEvent.KEY_PRESSED, time, flags, vk, ch); } catch (UnsupportedKeyException e) { if ((flags & InputEvent.SHIFT_DOWN_MASK) != 0) { ch = ucharMap[scancode]; } else if((flags & InputEvent.ALT_GRAPH_DOWN_MASK) != 0) { ch = altGrCharMap[scancode]; } else { ch = lcharMap[scancode]; } long time = System.currentTimeMillis(); lastScancode = scancode; return new KeyboardEvent(released ? KeyEvent.KEY_RELEASED : KeyEvent.KEY_PRESSED, time, flags, vk, ch); } catch (DeadKeyException e) { return null; } } else { lastScancode = scancode; return null; } } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/57843b9b284ea62b4a1db76be6395f975acfd0fc/KeyboardInterpreter.java/buggy/core/src/driver/org/jnode/driver/input/KeyboardInterpreter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
16535,
1133,
10634,
7972,
710,
12,
474,
4135,
710,
13,
288,
9506,
202,
430,
261,
9871,
710,
422,
1139,
56,
67,
4142,
22088,
13,
288,
1082,
202,
2722,
7972,
710,
273,
4135,
710... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
16535,
1133,
10634,
7972,
710,
12,
474,
4135,
710,
13,
288,
9506,
202,
430,
261,
9871,
710,
422,
1139,
56,
67,
4142,
22088,
13,
288,
1082,
202,
2722,
7972,
710,
273,
4135,
710... |
moreFeatures = scorer.calculateScores(stream.getActiveList().getTokens()); | Scoreable scoreable = scorer.calculateScores(stream.getActiveList().getTokens()); moreFeatures = (scoreable != null); | private boolean score() { scoreTimer.start(); debugPrint("Scoring"); boolean moreFeatures = false; for (Iterator i = FeatureStream.iterator(); i.hasNext();) { FeatureStream stream = (FeatureStream) i.next(); moreFeatures = scorer.calculateScores(stream.getActiveList().getTokens()); } debugPrint(" done Scoring"); scoreTimer.stop(); return moreFeatures; } | 7874 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7874/73dc8e7fcf5a4060c4352b547fb900eac9db7b94/ParallelSearchManager.java/buggy/edu/cmu/sphinx/research/parallel/ParallelSearchManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1250,
4462,
1435,
288,
202,
6355,
6777,
18,
1937,
5621,
202,
4148,
5108,
2932,
1541,
6053,
8863,
202,
6494,
1898,
8696,
273,
629,
31,
202,
1884,
261,
3198,
277,
273,
7881,
1228,
18,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1250,
4462,
1435,
288,
202,
6355,
6777,
18,
1937,
5621,
202,
4148,
5108,
2932,
1541,
6053,
8863,
202,
6494,
1898,
8696,
273,
629,
31,
202,
1884,
261,
3198,
277,
273,
7881,
1228,
18,... |
public Bond[] getConnectedBonds(Atom atom) throws Exception | public Bond[] getConnectedBonds(Atom atom) | public Bond[] getConnectedBonds(Atom atom) throws Exception { Bond[] bonds = new Bond[atom.getDegree()]; Bond bond; int conBondCount = 0; for (int i = 0; i < bondCount; i++) { bond = bonds[i]; if (bond.contains(atom)) { bonds[conBondCount] = bond; conBondCount++; } } if (atom.getDegree() != conBondCount) { throw new Exception("wrong number of connected Bonds"); } return bonds; } | 46046 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46046/0ccdc81fbb854cafbe76975fa2e13098b1b51c00/AtomContainer.java/buggy/org/openscience/cdk/AtomContainer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
605,
1434,
8526,
336,
8932,
26090,
12,
3641,
3179,
13,
1216,
1185,
202,
95,
202,
202,
9807,
8526,
15692,
273,
394,
605,
1434,
63,
7466,
18,
588,
22885,
1435,
15533,
202,
202,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
605,
1434,
8526,
336,
8932,
26090,
12,
3641,
3179,
13,
1216,
1185,
202,
95,
202,
202,
9807,
8526,
15692,
273,
394,
605,
1434,
63,
7466,
18,
588,
22885,
1435,
15533,
202,
202,
... |
if (verboseJNI) VM.sysWrite("JNI called: CallNonvirtualLongMethod \n"); | if (traceJNI) VM.sysWrite("JNI called: CallNonvirtualLongMethod \n"); | private static long CallNonvirtualLongMethod(int envJREF, int objJREF, int classJREF, int methodID) throws Exception { if (verboseJNI) VM.sysWrite("JNI called: CallNonvirtualLongMethod \n"); VM_JNIEnvironment env; try { // dereference the object instance env = VM_Thread.getCurrentThread().getJNIEnv(); Object obj = env.getJNIRef(objJREF); Object returnObj = VM_JNIEnvironment.invokeWithDotDotVarArg(obj, methodID, VM_Type.LongType, true); return VM_Reflection.unwrapLong(returnObj); // should be a wrapper for a long value } catch (Throwable unexpected) { env = VM_Thread.getCurrentThread().getJNIEnv(); env.recordException(unexpected); return 0; } } | 5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/09d8a822a8cf16e16c97ebb4496b4febb2e197a3/VM_JNIFunctions.java/clean/rvm/src/vm/jni/VM_JNIFunctions.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
760,
1525,
3049,
3989,
12384,
3708,
1305,
12,
474,
1550,
46,
10771,
16,
509,
1081,
46,
10771,
16,
509,
667,
46,
10771,
16,
509,
707,
734,
13,
565,
1216,
1185,
288,
1377,
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,
282,
3238,
760,
1525,
3049,
3989,
12384,
3708,
1305,
12,
474,
1550,
46,
10771,
16,
509,
1081,
46,
10771,
16,
509,
667,
46,
10771,
16,
509,
707,
734,
13,
565,
1216,
1185,
288,
1377,
309,
261,... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.