rem stringlengths 1 53.3k | add stringlengths 0 80.5k | context stringlengths 6 326k | meta stringlengths 141 403 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|---|
scY.computeTicks( ids, | int tickCount = scY.computeTicks( ids, | private final double adjustVerticalDueToHorizontal( double dBlockY, double dBlockHeight, AllAxes aax ) throws ChartException, IllegalArgumentException { final OneAxis axPH = aax.areAxesSwapped( ) ? aax.getPrimaryOrthogonal( ) : aax.getPrimaryBase( ); final OneAxis axPV = aax.areAxesSwapped( ) ? aax.getPrimaryBase( ) : aax.getPrimaryOrthogonal( ); final AutoScale scX = axPH.getScale( ); final AutoScale scY = axPV.getScale( ); final int iXLabelLocation = axPH.getLabelPosition( ); final int iYLabelLocation = axPV.getLabelPosition( ); final int iXTitleLocation = axPH.getTitlePosition( ); final Label laXAxisTitle = axPH.getTitle( ); final Label laYAxisLabels = axPV.getLabel( ); final int iXTickStyle = axPH.getCombinedTickStyle( ); final IntersectionValue iv = axPH.getIntersectionValue( ); // COMPUTE THE THICKNESS OF THE AXIS INCLUDING AXIS LABEL BOUNDS AND // AXIS-PLOT SPACING double dXAxisLabelsThickness = scX.computeAxisLabelThickness( ids, axPH.getLabel( ), HORIZONTAL ); double dXAxisTitleThickness = 0; if ( laXAxisTitle.isVisible( ) ) { final String sPreviousValue = laXAxisTitle.getCaption( ).getValue( ); laXAxisTitle.getCaption( ) .setValue( rtc.externalizedMessage( sPreviousValue ) ); // EXTERNALIZE try { dXAxisTitleThickness = computeBox( ids, iXTitleLocation, laXAxisTitle, 0, 0 ).getHeight( ); } catch ( IllegalArgumentException uiex ) { throw new ChartException( ChartEnginePlugin.ID, ChartException.GENERATION, uiex ); } finally { laXAxisTitle.getCaption( ).setValue( sPreviousValue ); // RESTORE } } double dY = getLocation( scY, iv ), dY1 = dY, dY2 = dY; // X-AXIS BAND // VERTICAL // CO-ORDINATES final boolean bTicksAbove = ( iXTickStyle & TICK_ABOVE ) == TICK_ABOVE; // 'boolean' // FOR // CONVENIENCE // & // READABILITY final boolean bTicksBelow = ( iXTickStyle & TICK_BELOW ) == TICK_BELOW; // 'boolean' // FOR // CONVENIENCE // & // READABILITY final double dAppliedXAxisPlotSpacing = ( iv.iType == IntersectionValue.MAX || iv.iType == IntersectionValue.MIN ) ? dXAxisPlotSpacing : 0; // COMPUTE VALUES FOR y1, y, y2 // y = VERTICAL LOCATION OF X-AXIS ALONG PLOT // y1 = UPPER EDGE OF X-AXIS (DUE TO AXIS LABELS, TICKS, SPACING) // y2 = LOWER EDGE OF X-AXIS (DUE TO AXIS LABELS, TICKS, SPACING) if ( iv.iType == IntersectionValue.MAX ) { // NOTE: ENSURE CODE SYMMETRY WITH 'InsersectionValue.MIN' dY -= dAppliedXAxisPlotSpacing; dY1 = dY; dY2 = dY; if ( bTicksAbove ) { dY1 -= TICK_SIZE; } if ( iXLabelLocation == ABOVE ) { dY1 -= dXAxisLabelsThickness; dY2 += Math.max( bTicksBelow ? TICK_SIZE : 0, dAppliedXAxisPlotSpacing ); } else if ( iXLabelLocation == BELOW ) { dY2 += Math.max( ( bTicksBelow ? TICK_SIZE : 0 ) + dXAxisLabelsThickness, dAppliedXAxisPlotSpacing ); } if ( iXTitleLocation == ABOVE ) { dY1 -= dXAxisTitleThickness; } else if ( iXTitleLocation == BELOW ) { dY2 += dXAxisTitleThickness; } // ENSURE THAT WE DON'T GO ABOVE THE UPPER PLOT BLOCK EDGE if ( dY1 < dBlockY ) { final double dDelta = ( dBlockY - dY1 ); dY1 = dBlockY; dY += dDelta; dY2 += dDelta; } double dDeltaY1 = dY - dY1; double dDeltaY2 = dY2 - dY; // COMPUTE THE X-AXIS BAND THICKNESS AND ADJUST Y2 FOR LABELS BELOW dXAxisLabelsThickness = 0; // REUSE VARIABLE if ( iXLabelLocation == ABOVE ) { // X-AXIS BAND IS (y1 -> y2) dXAxisLabelsThickness = dY2 - dY1; } else if ( iXLabelLocation == BELOW ) { // X-AXIS BAND IS (y1 -> (y+AxisPlotSpacing)) dY2 = ( dY + dAppliedXAxisPlotSpacing ); dXAxisLabelsThickness = dY2 - dY1; } // CHECK IF X-AXIS THICKNESS REQUIRES A PLOT HEIGHT RESIZE AT THE // UPPER END if ( dXAxisLabelsThickness > scY.getEndShift( ) ) { // REDUCE scY's ENDPOINT TO FIT THE X-AXIS AT THE TOP scY.setEndPoints( scY.getStart( ) + scY.getStartShift( ), scY.getEnd( ) - scY.getEndShift( ) ); double dStart = scY.getStart( ), dEnd = dY2 - scY.getEndShift( ); scY.resetShifts( ); // LOOP THAT AUTO-RESIZES Y-AXIS AND RE-COMPUTES Y-AXIS LABELS // IF OVERLAPS OCCUR scY.setEndPoints( dStart, dEnd ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); if ( !scY.isStepFixed( ) ) { final Object[] oaMinMax = scY.getMinMax( ); while ( !scY.checkFit( ids, laYAxisLabels, iYLabelLocation ) ) { scY.zoomOut( ); scY.updateAxisMinMax( oaMinMax[0], oaMinMax[1] ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); } } } dY -= insCA.getTop( ); dY1 = dY - dDeltaY1; dY2 = dY + dDeltaY2; axPH.setTitleCoordinate( ( iXTitleLocation == ABOVE ) ? dY1 - 1 : dY2 + 1 - dXAxisTitleThickness ); } else if ( iv.iType == IntersectionValue.MIN ) { // NOTE: ENSURE CODE SYMMETRY WITH 'InsersectionValue.MAX' dY += dAppliedXAxisPlotSpacing; dY1 = dY; dY2 = dY; if ( bTicksBelow ) { dY2 += TICK_SIZE; } if ( iXLabelLocation == ABOVE ) { dY1 -= Math.max( ( bTicksAbove ? TICK_SIZE : 0 ) + dXAxisLabelsThickness, dAppliedXAxisPlotSpacing ); } else if ( iXLabelLocation == BELOW ) { dY2 += dXAxisLabelsThickness; dY1 -= Math.max( bTicksAbove ? TICK_SIZE : 0, dAppliedXAxisPlotSpacing ); } if ( iXTitleLocation == ABOVE ) { dY1 -= dXAxisTitleThickness; } else if ( iXTitleLocation == BELOW ) { dY2 += dXAxisTitleThickness; } // ENSURE THAT WE DON'T GO BELOW THE LOWER PLOT BLOCK EDGE if ( dY2 > dBlockY + dBlockHeight ) { final double dDelta = ( dY2 - ( dBlockY + dBlockHeight ) ); dY2 = dBlockY + dBlockHeight; dY -= dDelta; dY1 -= dDelta; } double dDeltaY1 = dY - dY1; double dDeltaY2 = dY2 - dY; // COMPUTE THE X-AXIS BAND THICKNESS AND ADJUST Y2 FOR LABELS BELOW dXAxisLabelsThickness = 0; // REUSE VARIABLE if ( iXLabelLocation == ABOVE ) { // X-AXIS BAND IS ((y+AxisPlotSpacing) -> y2) dY1 = ( dY - dAppliedXAxisPlotSpacing ); dXAxisLabelsThickness = dY2 - dY1; } else if ( iXLabelLocation == BELOW ) { // X-AXIS BAND IS (y1 -> y2) dXAxisLabelsThickness = dY2 - dY1; } // CHECK IF X-AXIS THICKNESS REQUIRES A PLOT HEIGHT RESIZE AT THE // LOWER END if ( dXAxisLabelsThickness > scY.getStartShift( ) ) { // REDUCE scY's STARTPOINT TO FIT THE X-AXIS AT THE TOP scY.setEndPoints( scY.getStart( ) + scY.getStartShift( ), scY.getEnd( ) - scY.getEndShift( ) ); // RESTORE double dStart = dY1 + scY.getStartShift( ), dEnd = scY.getEnd( ); scY.resetShifts( ); // LOOP THAT AUTO-RESIZES Y-AXIS AND RE-COMPUTES Y-AXIS LABELS // IF OVERLAPS OCCUR scY.setEndPoints( dStart, dEnd ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); if ( !scY.isStepFixed( ) ) { final Object[] oaMinMax = scY.getMinMax( ); while ( !scY.checkFit( ids, laYAxisLabels, iYLabelLocation ) ) { scY.zoomOut( ); scY.updateAxisMinMax( oaMinMax[0], oaMinMax[1] ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); } } } // MOVE THE BAND DOWNWARDS BY INSETS.BOTTOM dY += insCA.getBottom( ); dY1 = dY - dDeltaY1; dY2 = dY + dDeltaY2; // SET THE AXIS TITLE's BOX TOP CO-ORDINATE axPH.setTitleCoordinate( ( iXTitleLocation == ABOVE ) ? dY1 - 1 : dY2 + 1 - dXAxisTitleThickness ); } else { double dDeltaY1 = 0, dDeltaY2 = 0; if ( iXLabelLocation == ABOVE ) { dY1 -= ( bTicksAbove ? TICK_SIZE : 0 ) + dXAxisLabelsThickness; dY2 += ( bTicksBelow ? TICK_SIZE : 0 ); if ( iXTitleLocation == ABOVE ) { dY1 -= dXAxisTitleThickness; } else if ( iXTitleLocation == BELOW ) { dY2 += dXAxisTitleThickness; } dDeltaY1 = dY - dY1; dDeltaY2 = dY2 - dY; // CHECK IF UPPER EDGE OF X-AXIS BAND GOES ABOVE PLOT UPPER EDGE if ( dY1 < dBlockY ) { final Object[] oaMinMax = scY.getMinMax( ); boolean bForceBreak = false; // A LOOP THAT ITERATIVELY ATTEMPTS TO ADJUST THE TOP EDGE // OF THE X-AXIS LABELS WITH THE TOP EDGE OF THE PLOT AND/OR // ENSURE THAT THE END POINT OF THE Y-AXIS SCALE IS SUITABLY // POSITIONED do { // CANCEL OUT THE END LABEL SHIFT COMPUTATIONS FROM THE // Y-AXIS scY.setEndPoints( scY.getStart( ) + scY.getStartShift( ), scY.getEnd( ) - scY.getEndShift( ) ); // RESTORE scY.resetShifts( ); // APPLY THE AXIS REDUCTION FORMULA W.R.T. Y-AXIS // ENDPOINT double[] da = scY.getEndPoints( ); double dT_RI = dBlockY - dY1; // THRESHOLD - // REQUESTEDINTERSECTION double dAMin_AMax = da[0] - da[1]; double dAMin_RI = da[0] - dY; double dStart = da[0]; double dEnd = ( dT_RI / dAMin_RI ) * dAMin_AMax + da[1]; if ( dEnd < dBlockY ) { dEnd = dBlockY; bForceBreak = true; // ADJUST THE TOP EDGE OF THE // Y-AXIS SCALE TO THE TOP EDGE // OF THE PLOT BLOCK } // LOOP THAT AUTO-RESIZES Y-AXIS AND RE-COMPUTES Y-AXIS // LABELS IF OVERLAPS OCCUR scY.setEndPoints( dStart, dEnd ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); if ( !scY.isStepFixed( ) ) { while ( !scY.checkFit( ids, laYAxisLabels, iYLabelLocation ) ) { scY.zoomOut( ); scY.updateAxisMinMax( oaMinMax[0], oaMinMax[1] ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); } } dY = getLocation( scY, iv ); dY1 = dY - dDeltaY1; // RE-CALCULATE X-AXIS BAND // UPPER // EDGE dY2 = dY + dDeltaY2; // REDUNDANT: RE-CALCULATE // X-AXIS // BAND LOWER EDGE } while ( Math.abs( dY1 - dBlockY ) > 1 && !bForceBreak ); } } else if ( iXLabelLocation == BELOW ) { dY1 -= ( bTicksAbove ? TICK_SIZE : 0 ); dY2 += ( bTicksBelow ? TICK_SIZE : 0 ) + dXAxisLabelsThickness; if ( iXTitleLocation == ABOVE ) { dY1 -= dXAxisTitleThickness; } else if ( iXTitleLocation == BELOW ) { dY2 += dXAxisTitleThickness; } dDeltaY1 = dY - dY1; dDeltaY2 = dY2 - dY; // CHECK IF LOWER EDGE OF X-AXIS BAND GOES BELOW PLOT LOWER EDGE if ( dY2 > dBlockY + dBlockHeight ) { final Object[] oaMinMax = scY.getMinMax( ); boolean bForceBreak = false; // A LOOP THAT ITERATIVELY ATTEMPTS TO ADJUST THE TOP EDGE // OF THE X-AXIS LABELS WITH THE TOP EDGE OF THE PLOT AND/OR // ENSURE THAT THE END POINT OF THE Y-AXIS SCALE IS SUITABLY // POSITIONED do { // CANCEL OUT THE END LABEL SHIFT COMPUTATIONS FROM THE // Y-AXIS scY.setEndPoints( scY.getStart( ) + scY.getStartShift( ), scY.getEnd( ) - scY.getEndShift( ) ); // RESTORE scY.resetShifts( ); // APPLY THE AXIS REDUCTION FORMULA W.R.T. Y-AXIS // ENDPOINT double[] da = scY.getEndPoints( ); double dX2_X1 = dY2 - ( dBlockY + dBlockHeight ); // THRESHOLD // - // REQUESTEDINTERSECTION double dAMin_AMax = da[0] - da[1]; double dX2_AMax = dY - da[1]; double dStart = da[0] - ( dX2_X1 / dX2_AMax ) * dAMin_AMax; double dEnd = da[1]; if ( dStart > dBlockY + dBlockHeight ) { dStart = dBlockY + dBlockHeight; bForceBreak = true; // ADJUST THE TOP EDGE OF THE // Y-AXIS SCALE TO THE TOP EDGE // OF THE PLOT BLOCK } // LOOP THAT AUTO-RESIZES Y-AXIS AND RE-COMPUTES Y-AXIS // LABELS IF OVERLAPS OCCUR scY.setEndPoints( dStart, dEnd ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); if ( !scY.isStepFixed( ) ) { while ( !scY.checkFit( ids, laYAxisLabels, iYLabelLocation ) ) { scY.zoomOut( ); scY.updateAxisMinMax( oaMinMax[0], oaMinMax[1] ); scY.computeTicks( ids, laYAxisLabels, iYLabelLocation, VERTICAL, dStart, dEnd, true, aax ); } } dY = getLocation( scY, iv ); dY2 = dY + dDeltaY2; // RE-CALCULATE X-AXIS BAND // LOWER // EDGE dY1 = dY - dDeltaY1; // RE-CALCULATE X-AXIS BAND // LOWER // EDGE } while ( Math.abs( dY2 - ( dBlockY + dBlockHeight ) ) > 1 && !bForceBreak ); } } axPH.setTitleCoordinate( ( iXTitleLocation == ABOVE ) ? dY1 - 1 : dY2 + 1 - dXAxisTitleThickness ); } return dY; } | 12803 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12803/b73466ca03eaebb828003ae9a0f931431d353aa9/PlotWith2DAxes.java/buggy/chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/computation/withaxes/PlotWith2DAxes.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
727,
1645,
5765,
15704,
30023,
774,
14457,
12,
1645,
302,
1768,
61,
16,
1082,
202,
9056,
302,
1768,
2686,
16,
4826,
26494,
279,
651,
262,
1216,
14804,
503,
16,
1082,
202,
31237... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
727,
1645,
5765,
15704,
30023,
774,
14457,
12,
1645,
302,
1768,
61,
16,
1082,
202,
9056,
302,
1768,
2686,
16,
4826,
26494,
279,
651,
262,
1216,
14804,
503,
16,
1082,
202,
31237... |
public PartitionActiveList(SphinxProperties props) { setProperties(props); | public PartitionActiveList() { | public PartitionActiveList(SphinxProperties props) { setProperties(props); } | 8321 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8321/5f8e447fceb2ab9d1974888219dc6e6253e9429e/PartitionActiveList.java/buggy/sphinx4/edu/cmu/sphinx/decoder/search/PartitionActiveList.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
12598,
3896,
682,
12,
55,
15922,
2297,
3458,
13,
288,
202,
542,
2297,
12,
9693,
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,
... | [
1,
1,
1,
1,
1,
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,
12598,
3896,
682,
12,
55,
15922,
2297,
3458,
13,
288,
202,
542,
2297,
12,
9693,
1769,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
public TransientNode(String n) { | public TransientNode() { | public TransientNode(String n) { id = generateID(); name = ((n == null) || "".equals(n)) ? id : n; created = lastmodified = System.currentTimeMillis(); } | 46029 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46029/2f39d4f9080cbaa258e99279b7b1c5a043cd34e3/TransientNode.java/buggy/src/helma/objectmodel/TransientNode.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
28521,
907,
1435,
288,
3639,
612,
273,
2103,
734,
5621,
3639,
508,
273,
14015,
82,
422,
446,
13,
747,
1408,
18,
14963,
12,
82,
3719,
692,
612,
294,
290,
31,
3639,
2522,
273,
1142,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
28521,
907,
1435,
288,
3639,
612,
273,
2103,
734,
5621,
3639,
508,
273,
14015,
82,
422,
446,
13,
747,
1408,
18,
14963,
12,
82,
3719,
692,
612,
294,
290,
31,
3639,
2522,
273,
1142,... |
writer.setOutput(socket.getOutputStream()); | writer.setOutput(new JiBXOutputStreamWrapper(socket.getOutputStream())); | public void handle(Socket socket) throws IOException { connCtx.setSocket(socket); try { //set socket keepalive socket.setKeepAlive(true); //by setting output and document, the writer and unmarshalling // context //will get resetted writer.setOutput(socket.getOutputStream()); uctx.setDocument(new InputStreamReader(socket.getInputStream(), "UTF-8")); //handshake processing XMPPClientHandshakeStream handshakeStream = new XMPPClientHandshakeStream(); handshakeStream.process(clientCtx, connCtx, uctx, writer); //Determine whether to do TLS processing if (connCtx.isTLSSupported()) { TLSHandshakeStream tlsStream = new TLSHandshakeStream(); tlsStream.process(clientCtx, connCtx, uctx, writer); socket = connCtx.getSocket(); //redo the handshake process handshakeStream.process(clientCtx, connCtx, uctx, writer); } //Determine whether to do SASL processing //Start normal session processing } catch (Exception ex) { if (log.isWarnEnabled()) log.warn("Exception occurred during socket processing", ex); } finally { //disconnected from server, close streams but not the socket if (writer != null) writer.close(); shutdown(); } } | 11079 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11079/8e352b3a2802ed727054b2253e4bcbaa4ab26dd5/XMPPConnectionHandler.java/buggy/muse/branch/1.0a1/src/xmpp/com/echomine/xmpp/XMPPConnectionHandler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1640,
12,
4534,
2987,
13,
1216,
1860,
288,
3639,
1487,
6442,
18,
542,
4534,
12,
7814,
1769,
3639,
775,
288,
5411,
368,
542,
2987,
26210,
5411,
2987,
18,
542,
24456,
12,
3767,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1640,
12,
4534,
2987,
13,
1216,
1860,
288,
3639,
1487,
6442,
18,
542,
4534,
12,
7814,
1769,
3639,
775,
288,
5411,
368,
542,
2987,
26210,
5411,
2987,
18,
542,
24456,
12,
3767,
... |
public org.quickfix.field.SecurityIDSource getSecurityIDSource() throws FieldNotFound { org.quickfix.field.SecurityIDSource value = new org.quickfix.field.SecurityIDSource(); | public quickfix.field.SecurityIDSource getSecurityIDSource() throws FieldNotFound { quickfix.field.SecurityIDSource value = new quickfix.field.SecurityIDSource(); | public org.quickfix.field.SecurityIDSource getSecurityIDSource() throws FieldNotFound { org.quickfix.field.SecurityIDSource value = new org.quickfix.field.SecurityIDSource(); getField(value); return value; } | 8803 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8803/fecc27f98261270772ff182a1d4dfd94b5daa73d/NewOrderList.java/clean/src/java/src/quickfix/fix44/NewOrderList.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
4368,
734,
1830,
19288,
734,
1830,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
4368,
734,
1830,
460,
273,
394,
2358,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
2358,
18,
19525,
904,
18,
1518,
18,
4368,
734,
1830,
19288,
734,
1830,
1435,
1216,
2286,
2768,
225,
288,
2358,
18,
19525,
904,
18,
1518,
18,
4368,
734,
1830,
460,
273,
394,
2358,
... |
buffer.append(TAB + AT + ECHO + WHITESPACE + SINGLE_QUOTE + MESSAGE_FINISH_FILE + WHITESPACE + IN_MACRO + SINGLE_QUOTE + NEWLINE); buffer.append(TAB + AT + ECHO + WHITESPACE + SINGLE_QUOTE + WHITESPACE + SINGLE_QUOTE + NEWLINE + NEWLINE); | buffer.append(TAB + AT + escapedEcho(MESSAGE_FINISH_FILE + WHITESPACE + IN_MACRO)); buffer.append(TAB + AT + ECHO_BLANK_LINE + NEWLINE); | protected void addRuleForSource(String relativePath, StringBuffer buffer, IResource resource, IPath sourceLocation, IResourceConfiguration resConfig, boolean generatedSource, StringBuffer generatedDepFile, Vector enumeratedOutputs) { String fileName = sourceLocation.removeFileExtension().lastSegment(); String inputExtension = sourceLocation.getFileExtension(); String outputExtension = info.getOutputExtension(inputExtension); ITool tool = null; if( resConfig != null) { ITool[] tools = resConfig.getToolsToInvoke(); if (tools != null && tools.length > 0) { tool = tools[0]; } } if (tool == null) { tool = info.getToolFromInputExtension(inputExtension); } // Get the dependency generator associated with this tool and file extension IManagedDependencyGenerator depGen = tool.getDependencyGeneratorForExtension(inputExtension); boolean doDepGen = (depGen != null && depGen.getCalculatorType() == IManagedDependencyGenerator.TYPE_COMMAND); // If the tool creates a dependency file, add it to the list if (doDepGen) { String depFile = relativePath + fileName + DOT + DEP_EXT; getDependencyMakefiles().add(depFile); generatedDepFile.append(fileName + DOT + DEP_EXT); } // Figure out the output paths String OptDotExt = EMPTY_STRING; if (outputExtension != null && outputExtension.length() > 0) OptDotExt = DOT + outputExtension; Vector ruleOutputs = new Vector(); Vector enumeratedPrimaryOutputs = new Vector(); Vector enumeratedSecondaryOutputs = new Vector(); calculateOutputsForSource(tool, relativePath, resource, sourceLocation, ruleOutputs, enumeratedPrimaryOutputs, enumeratedSecondaryOutputs); enumeratedOutputs.addAll(enumeratedPrimaryOutputs); enumeratedOutputs.addAll(enumeratedSecondaryOutputs); String primaryOutputName = null; if (enumeratedPrimaryOutputs.size() > 0) { primaryOutputName = escapeWhitespaces(((IPath)enumeratedPrimaryOutputs.get(0)).toString()); } else { primaryOutputName = escapeWhitespaces(relativePath + fileName + OptDotExt); } String otherPrimaryOutputs = EMPTY_STRING; for (int i=1; i<enumeratedPrimaryOutputs.size(); i++) { // Starting a 1 is intentional otherPrimaryOutputs += WHITESPACE + escapeWhitespaces(((IPath)enumeratedPrimaryOutputs.get(i)).toString()); } // Figure out the path to the input resource /* * fix for PR 70491 * We need to check if the current resource is LINKED, because * the default CDT doesn't handle this properly. If it IS linked, * then we must get the actual location of the resource, rather * than the relative path. */ String projectLocation = project.getLocation().toString(); // Optput file location needed for the file-specific build macros IPath outputLocation = Path.fromOSString(primaryOutputName); if (!outputLocation.isAbsolute()) { outputLocation = project.getLocation().append(getBuildWorkingDir()).append(primaryOutputName); } // A separate rule is needed for the resource in case the explicit file-specific macros // are referenced, or if the resource contains special characters in its path boolean needExplicitRuleForFile = containsSpecialCharacters(sourceLocation.toString()) || //$NON-NLS-1$ MacroResolver.getReferencedExplitFileMacros(tool).length > 0 || MacroResolver.getReferencedExplitFileMacros(tool .getToolCommand(), IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)).length > 0; //get and resolve command String cmd = tool.getToolCommand(); try { String resolvedCommand = null; if (!needExplicitRuleForFile) { resolvedCommand = ManagedBuildManager.getBuildMacroProvider() .resolveValueToMakefileFormat( cmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } else { // if we need an explicit rule then don't use any builder // variables, resolve everything // to explicit strings resolvedCommand = ManagedBuildManager.getBuildMacroProvider() .resolveValue( cmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } if ((resolvedCommand = resolvedCommand.trim()).length() > 0) cmd = resolvedCommand; } catch (BuildMacroException e) { } String defaultOutputName = EMPTY_STRING; String primaryDependencyName = EMPTY_STRING; String home = (generatedSource)? DOT : ROOT; String resourcePath = null; boolean patternRule = true; //boolean isItLinked = false; //if (resource.isLinked()) { NOTE: we don't use this since children of linked resources return false if(!sourceLocation.toString().startsWith(projectLocation)) { // it IS linked, so use the actual location //isItLinked = true; resourcePath = sourceLocation.toString(); // Need a hardcoded rule, not a pattern rule, as a linked file // can reside in any path defaultOutputName = escapeWhitespaces(relativePath + fileName + OptDotExt); primaryDependencyName = escapeWhitespaces(resourcePath); patternRule = false; } else { // use the relative path (not really needed to store per se but in the future someone may want this) resourcePath = relativePath; // The rule and command to add to the makefile if( resConfig != null || needExplicitRuleForFile) { // Need a hardcoded rule, not a pattern rule defaultOutputName = escapeWhitespaces(resourcePath + fileName + OptDotExt); primaryDependencyName = escapeWhitespaces(home + SEPARATOR + resourcePath + fileName + DOT + inputExtension); patternRule = false; } else { defaultOutputName = relativePath + WILDCARD + OptDotExt; primaryDependencyName = home + SEPARATOR + resourcePath + WILDCARD + DOT + inputExtension; } } // end fix for PR 70491 // If we still think that we are using a pattern rule, make sure that at least one of the rule // outputs contains a %. if (patternRule) { patternRule = false; for (int i=0; i<ruleOutputs.size(); i++) { String ruleOutput = ((IPath)ruleOutputs.get(i)).toString(); if (ruleOutput.indexOf('%') >= 0) { //$NON-NLS-1$ patternRule = true; break; } } if (!patternRule) { // Need to reset the primary dependency to be a filename rather than a pattern primaryDependencyName = escapeWhitespaces(home + SEPARATOR + resourcePath + fileName + DOT + inputExtension); } } // Begin building the rule for this source file String buildRule = EMPTY_STRING; if (patternRule) { if (ruleOutputs.size() == 0) { buildRule = defaultOutputName; } else { boolean first = true; for (int i=0; i<ruleOutputs.size(); i++) { String ruleOutput = ((IPath)ruleOutputs.get(i)).toString(); if (ruleOutput.indexOf('%') >= 0) { //$NON-NLS-1$ if (first) { first = false; } else { buildRule += WHITESPACE; } buildRule += ruleOutput; } } } } else { buildRule += primaryOutputName; } buildRule += COLON + WHITESPACE + primaryDependencyName; // Other additional inputs // Get any additional dependencies specified for the tool in other InputType elements and AdditionalInput elements IPath[] addlDepPaths = tool.getAdditionalDependencies(); for (int i=0; i<addlDepPaths.length; i++) { // Translate the path from project relative to // build directory relative IPath addlPath = addlDepPaths[i]; if (!(addlPath.toString().startsWith("$("))) { //$NON-NLS-1$ if (!addlPath.isAbsolute()) { IPath tempPath = project.getLocation().append(addlPath); if (tempPath != null) { addlPath = ManagedBuildManager.calculateRelativePath(getTopBuildDir(), tempPath); } } } buildRule += WHITESPACE + escapeWhitespaces(addlPath.toString()); } // No duplicates in a makefile. If we already have this rule, don't add it or the commands to build the file if (getRuleList().contains(buildRule)) { // TODO: Should we assert that this is a pattern rule? } else { getRuleList().add(buildRule); // Echo starting message buffer.append(buildRule + NEWLINE); buffer.append(TAB + AT + ECHO + WHITESPACE + SINGLE_QUOTE + MESSAGE_START_FILE + WHITESPACE + IN_MACRO + SINGLE_QUOTE + NEWLINE); // Generate the command line IManagedCommandLineInfo cmdLInfo = null; Vector inputs = new Vector(); inputs.add(IN_MACRO); String outflag = null; String outputPrefix = null; if( resConfig != null || needExplicitRuleForFile) { buffer.append(TAB + AT + ECHO + WHITESPACE + SINGLE_QUOTE + tool.getAnnouncement() + SINGLE_QUOTE + NEWLINE); outflag = tool.getOutputFlag(); outputPrefix = tool.getOutputPrefix(); // Other additional inputs // Get any additional dependencies specified for the tool in other InputType elements and AdditionalInput elements IPath[] addlInputPaths = getAdditionalResourcesForSource(tool); for (int i=0; i<addlInputPaths.length; i++) { // Translate the path from project relative to // build directory relative IPath addlPath = addlInputPaths[i]; if (!(addlPath.toString().startsWith("$("))) { //$NON-NLS-1$ if (!addlPath.isAbsolute()) { IPath tempPath = project.getLocation().append(addlPath); if (tempPath != null) { addlPath = ManagedBuildManager.calculateRelativePath(getTopBuildDir(), tempPath); } } } inputs.add(addlPath.toString()); } String[] flags = null; // Get the tool command line options try { flags = tool.getToolCommandFlags(sourceLocation, outputLocation); } catch( BuildException ex ) { // TODO add some routines to catch this flags = EMPTY_STRING_ARRAY; } // Call the command line generator IManagedCommandLineGenerator cmdLGen = tool.getCommandLineGenerator(); cmdLInfo = cmdLGen.generateCommandLineInfo( tool, cmd, flags, outflag, outputPrefix, OUT_MACRO + otherPrimaryOutputs, (String[])inputs.toArray(new String[inputs.size()]), tool.getCommandLinePattern() ); String buildCmd = cmdLInfo.getCommandLine(); // resolve any remaining macros in the command after it has been // generated try { String resolvedCommand = null; if (!needExplicitRuleForFile) { resolvedCommand = ManagedBuildManager.getBuildMacroProvider() .resolveValueToMakefileFormat( buildCmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } else { // if we need an explicit rule then don't use any builder // variables, resolve everything // to explicit strings resolvedCommand = ManagedBuildManager.getBuildMacroProvider() .resolveValue( buildCmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } if ((resolvedCommand = resolvedCommand.trim()).length() > 0) buildCmd = resolvedCommand; } catch (BuildMacroException e) { } buffer.append(TAB + AT + ECHO + WHITESPACE + buildCmd + NEWLINE); buffer.append(TAB + AT + buildCmd); } else { buffer.append(TAB + AT + ECHO + WHITESPACE + SINGLE_QUOTE + tool.getAnnouncement() + SINGLE_QUOTE + NEWLINE); outflag = info.getOutputFlag(outputExtension); outputPrefix = info.getOutputPrefix(outputExtension); // Other additional inputs // Get any additional dependencies specified for the tool in other InputType elements and AdditionalInput elements IPath[] addlInputPaths = getAdditionalResourcesForSource(tool); for (int i=0; i<addlInputPaths.length; i++) { // Translate the path from project relative to // build directory relative IPath addlPath = addlInputPaths[i]; if (!(addlPath.toString().startsWith("$("))) { //$NON-NLS-1$ if (!addlPath.isAbsolute()) { IPath tempPath = project.getLocation().append(addlPath); if (tempPath != null) { addlPath = ManagedBuildManager.calculateRelativePath(getTopBuildDir(), tempPath); } } } inputs.add(addlPath.toString()); } // Get the tool command line options String buildFlags = EMPTY_STRING; try { buildFlags = tool.getToolCommandFlagsString(sourceLocation, outputLocation); } catch (BuildException e) { } String[] flags = buildFlags.split( "\\s" ); //$NON-NLS-1$ // Call the command line generator cmdLInfo = info.generateToolCommandLineInfo( inputExtension, flags, outflag, outputPrefix, OUT_MACRO + otherPrimaryOutputs, (String[])inputs.toArray(new String[inputs.size()]), sourceLocation, outputLocation ); // The command to build String buildCmd = null; if( cmdLInfo == null ) buildCmd = cmd + WHITESPACE + buildFlags + WHITESPACE + outflag + WHITESPACE + outputPrefix + OUT_MACRO + otherPrimaryOutputs + WHITESPACE + IN_MACRO; else buildCmd = cmdLInfo.getCommandLine(); // resolve any remaining macros in the command after it has been // generated try { String resolvedCommand = null; if (!needExplicitRuleForFile) { resolvedCommand = ManagedBuildManager.getBuildMacroProvider() .resolveValueToMakefileFormat( buildCmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } else { // if we need an explicit rule then don't use any builder // variables, resolve everything // to explicit strings resolvedCommand = ManagedBuildManager.getBuildMacroProvider() .resolveValue( buildCmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } if ((resolvedCommand = resolvedCommand.trim()).length() > 0) buildCmd = resolvedCommand; } catch (BuildMacroException e) { } buffer.append(TAB + AT + ECHO + WHITESPACE + buildCmd + NEWLINE); buffer.append(TAB + AT + buildCmd); } // Determine if there are any dependencies to calculate // TODO: Note that there is an assumption built into this method that if the build rule is the same // for a set of resources, the dependency command will also be the same. That is, this method // will not reach this code if the build rule is the same (see above). if (doDepGen && depGen.getCalculatorType() == IManagedDependencyGenerator.TYPE_COMMAND) { buffer.append(WHITESPACE + LOGICAL_AND + WHITESPACE + LINEBREAK); // Get the dependency rule out of the generator String depCmd = depGen.getDependencyCommand(resource, info); // Resolve any macros in the dep command after it has been generated. // Note: do not trim the result because it will strip out necessary tab characters. try { if (!needExplicitRuleForFile) { depCmd = ManagedBuildManager.getBuildMacroProvider() .resolveValueToMakefileFormat( depCmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } else { depCmd = ManagedBuildManager.getBuildMacroProvider() .resolveValue( depCmd, EMPTY_STRING, WHITESPACE, IBuildMacroProvider.CONTEXT_FILE, new FileContextData(sourceLocation, outputLocation, null, tool)); } } catch (BuildMacroException e) { } buffer.append(depCmd); } // Echo finished message buffer.append(NEWLINE); buffer.append(TAB + AT + ECHO + WHITESPACE + SINGLE_QUOTE + MESSAGE_FINISH_FILE + WHITESPACE + IN_MACRO + SINGLE_QUOTE + NEWLINE); buffer.append(TAB + AT + ECHO + WHITESPACE + SINGLE_QUOTE + WHITESPACE + SINGLE_QUOTE + NEWLINE + NEWLINE); } // Determine if there are calculated dependencies String calculatedDependencies = null; boolean addedDepLines = false; String depLine; if (depGen != null && depGen.getCalculatorType() != IManagedDependencyGenerator.TYPE_COMMAND) { Vector addlDepsVector = calculateDependenciesForSource(depGen, tool, relativePath, resource); if (addlDepsVector != null && addlDepsVector.size() > 0) { calculatedDependencies = new String(); for (int i=0; i<addlDepsVector.size(); i++) { calculatedDependencies += WHITESPACE + addlDepsVector.get(i).toString(); } } } if (calculatedDependencies != null) { depLine = primaryOutputName + COLON + calculatedDependencies + NEWLINE; if (!getDepLineList().contains(depLine)) { getDepLineList().add(depLine); addedDepLines = true; buffer.append(depLine); } } // Add any additional outputs here using dependency lines for (int i=1; i<enumeratedPrimaryOutputs.size(); i++) { // Starting a 1 is intentional depLine = ((IPath)enumeratedPrimaryOutputs.get(i)).toString() + COLON + WHITESPACE + primaryOutputName; if (calculatedDependencies != null) depLine += calculatedDependencies; depLine += NEWLINE; if (!getDepLineList().contains(depLine)) { getDepLineList().add(depLine); addedDepLines = true; buffer.append(depLine); } } for (int i=0; i<enumeratedSecondaryOutputs.size(); i++) { depLine = ((IPath)enumeratedSecondaryOutputs.get(i)).toString() + COLON + WHITESPACE + primaryOutputName; if (calculatedDependencies != null) depLine += calculatedDependencies; depLine += NEWLINE; if (!getDepLineList().contains(depLine)) { getDepLineList().add(depLine); addedDepLines = true; buffer.append(depLine); } } if (addedDepLines) { buffer.append(NEWLINE); } } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/c7f73a40517ebbe266d35bf3a3c441c1f33003b8/GnuMakefileGenerator.java/clean/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/makegen/gnu/GnuMakefileGenerator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
918,
21264,
1290,
1830,
12,
780,
12820,
16,
6674,
1613,
16,
467,
1420,
1058,
16,
1875,
202,
45,
743,
1084,
2735,
16,
467,
1420,
1750,
400,
809,
16,
1875,
202,
6494,
4374,
183... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
21264,
1290,
1830,
12,
780,
12820,
16,
6674,
1613,
16,
467,
1420,
1058,
16,
1875,
202,
45,
743,
1084,
2735,
16,
467,
1420,
1750,
400,
809,
16,
1875,
202,
6494,
4374,
183... |
} | public void handle(PrintOutputStream pos) { getwrapper.wrapRunnable(new Runnable() { public void run() { presmanager.scopeRestore(); if (viewparams.flowtoken != null) { presmanager.restore(viewparams.flowtoken, viewparams.endflow != null); } // this must now be AFTER restoration since the templateexpander may // access the model. Shucks!! view = viewgenerator.getView(); // even a "read" from the model may want to cause a scope to be allocated. // it will have to be the user's responsibility not to violate idempotency. presmanager.scopePreserve(); viewprocessor.setView(view); view = viewprocessor.getProcessedView(); } }).run(); if (errorstatemanager.errorstate != null) { viewrender.setMessages(errorstatemanager.errorstate.errors); viewrender .setGlobalMessageTarget(errorstatemanager.errorstate.globaltargetid); } viewrender.setView(view); viewrender.render(pos); } | 29 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/29/56b3523946285606868660df147e6d31061d4b88/RSFRenderHandler.java/buggy/rsf-core/core/src/uk/org/ponder/rsf/processor/RSFRenderHandler.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
1640,
12,
5108,
4632,
949,
13,
288,
565,
336,
8376,
18,
4113,
20013,
12,
2704,
10254,
1435,
288,
1377,
1071,
918,
1086,
1435,
288,
3639,
4075,
4181,
18,
4887,
10874,
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,
282,
1071,
918,
1640,
12,
5108,
4632,
949,
13,
288,
565,
336,
8376,
18,
4113,
20013,
12,
2704,
10254,
1435,
288,
1377,
1071,
918,
1086,
1435,
288,
3639,
4075,
4181,
18,
4887,
10874,
5621,
3639... | |
public void testSuffix() throws Exception { SimpleRuleStore srs = new SimpleRuleStore(new ContextBase()); srs.addRule(new Pattern("a"), new XAction()); srs.addRule(new Pattern("a/*"), new YAction()); List r = srs.matchActions(new Pattern("a/b")); assertNotNull(r); assertEquals(1, r.size()); if (!(r.get(0) instanceof YAction)) { fail("Wrong type"); } } | 52049 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52049/b17afdd922fb715ce4d262907d6b474541e9bd32/SimpleStoreTest.java/buggy/logback-core/src/test/java/ch/qos/logback/core/joran/spi/SimpleStoreTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
6459,
3813,
5791,
1435,
15069,
503,
95,
5784,
2175,
13125,
5453,
33,
2704,
5784,
2175,
2257,
12,
2704,
1042,
2171,
10663,
87,
5453,
18,
1289,
2175,
12,
2704,
3234,
2932,
69,
6,
3631,
270... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
6459,
3813,
5791,
1435,
15069,
503,
95,
5784,
2175,
13125,
5453,
33,
2704,
5784,
2175,
2257,
12,
2704,
1042,
2171,
10663,
87,
5453,
18,
1289,
2175,
12,
2704,
3234,
2932,
69,
6,
3631,
270... | ||
if (colnr<1) | if (activeTableColumn<1) | public void keyPressed(KeyEvent e) { boolean right=false; boolean left=false; /* left = e.keyCode == SWT.ARROW_LEFT && last_carret_position==0; if (text!=null && !text.isDisposed()) right = e.keyCode == SWT.ARROW_RIGHT && last_carret_position==text.getText().length(); */ // "ENTER": close the text editor and copy the data over if ( e.character == SWT.CR || e.keyCode == SWT.ARROW_DOWN || e.keyCode == SWT.ARROW_UP || e.keyCode == SWT.TAB || left || right ) { TableItem row = cursor.getRow(); if (row==null) return; int rownr = table.indexOf(row); int colnr = cursor.getColumn(); applyTextChange(row, rownr, colnr); int maxcols=table.getColumnCount(); int maxrows=table.getItemCount(); boolean sel=false; if (e.keyCode == SWT.ARROW_DOWN && rownr<maxrows-1) { rownr++; sel=true; } if (e.keyCode == SWT.ARROW_UP && rownr>0) { rownr--; sel=true; } // TAB if ( ( e.keyCode == SWT.TAB && (( e.stateMask & SWT.SHIFT )==0 )) || right ) { colnr++; sel=true; } // Shift Tab if ( (e.keyCode == SWT.TAB && (( e.stateMask & SWT.SHIFT )!=0 )) || left ) { colnr--; sel=true; } if (colnr<1) // from SHIFT-TAB { colnr=maxcols-1; if (rownr>0) rownr--; } if (colnr>=maxcols) // from TAB { colnr=1; rownr++; } // Tab beyond last line: add a line to table! if (rownr>=maxrows) { TableItem item = new TableItem(table, SWT.NONE, rownr); item.setText(1, "field"+(table.getItemCount()-1)); setRowNums(); } if (sel) { row = table.getItem(rownr); edit(rownr, colnr); } } else if (e.keyCode == SWT.ESC) { text.dispose(); } last_carret_position = text.isDisposed()?-1:text.getCaretPosition(); } | 9547 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9547/653c48db4aa8dcc1152133aba6b314208d8d38ff/TableView.java/buggy/src/be/ibridge/kettle/core/widget/TableView.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
4697,
202,
482,
918,
498,
24624,
12,
653,
1133,
425,
13,
4697,
202,
95,
6862,
202,
6494,
2145,
33,
5743,
31,
6862,
202,
6494,
2002,
33,
5743,
31,
6862,
25083,
202,
20308,
6862,
202,
4482,
22... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
4697,
202,
482,
918,
498,
24624,
12,
653,
1133,
425,
13,
4697,
202,
95,
6862,
202,
6494,
2145,
33,
5743,
31,
6862,
202,
6494,
2002,
33,
5743,
31,
6862,
25083,
202,
20308,
6862,
202,
4482,
22... |
return bytesToPages(VM_Extent.fromInt(bytes)); | return bytesToPages(VM_Extent.fromIntZeroExtend(bytes)); | public static int bytesToPages(int bytes) { return bytesToPages(VM_Extent.fromInt(bytes)); } | 5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/bdb67e0d63a55453ab4c62f29eb1316ccc7bd1f0/Conversions.java/clean/MMTk/src/org/mmtk/utility/Conversions.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
760,
509,
1731,
774,
5716,
12,
474,
1731,
13,
288,
565,
327,
1731,
774,
5716,
12,
7397,
67,
17639,
18,
2080,
1702,
7170,
16675,
12,
3890,
10019,
225,
289,
2,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
760,
509,
1731,
774,
5716,
12,
474,
1731,
13,
288,
565,
327,
1731,
774,
5716,
12,
7397,
67,
17639,
18,
2080,
1702,
7170,
16675,
12,
3890,
10019,
225,
289,
2,
-100,
-100,
-100,
-10... |
XObject[] methodArgs; methodArgs = new XObject[args.size()]; try { for (int i = 0; i < methodArgs.length; i++) { methodArgs[i] = XObject.create(args.elementAt(i)); } ElemExsltFunction elemFunc = getFunction(funcName); XPathContext context = exprContext.getXPathContext(); TransformerImpl transformer = (TransformerImpl)context.getOwnerObject(); elemFunc.execute(transformer, methodArgs); VariableStack varStack = context.getVarStack(); XObject val = new XString(""); int resultIndex = elemFunc.getResultIndex(); if (varStack.isLocalSet(resultIndex)) val = varStack.getLocalVariable(context, resultIndex); return val; } catch (Exception e) { throw new TransformerException(e); } | throw new TransformerException("This method should not be called."); | public Object callFunction( String funcName, Vector args, Object methodKey, ExpressionContext exprContext) throws TransformerException { XObject[] methodArgs; methodArgs = new XObject[args.size()]; try { for (int i = 0; i < methodArgs.length; i++) { methodArgs[i] = XObject.create(args.elementAt(i)); } ElemExsltFunction elemFunc = getFunction(funcName); XPathContext context = exprContext.getXPathContext(); TransformerImpl transformer = (TransformerImpl)context.getOwnerObject(); elemFunc.execute(transformer, methodArgs); VariableStack varStack = context.getVarStack(); XObject val = new XString(""); // value returned if no result element. int resultIndex = elemFunc.getResultIndex(); if (varStack.isLocalSet(resultIndex)) val = varStack.getLocalVariable(context, resultIndex); return val; } catch (Exception e) { // e.printStackTrace(); throw new TransformerException(e); } } | 46591 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46591/078246d63e1c24f64893f4db615d8dcaf6f38d29/ExtensionHandlerExsltFunction.java/buggy/src/org/apache/xalan/extensions/ExtensionHandlerExsltFunction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1033,
745,
2083,
12,
1377,
514,
20810,
16,
5589,
833,
16,
1033,
707,
653,
16,
1377,
5371,
1042,
3065,
1042,
13,
1216,
21684,
225,
288,
565,
1139,
921,
8526,
707,
2615,
31,
565,
70... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1033,
745,
2083,
12,
1377,
514,
20810,
16,
5589,
833,
16,
1033,
707,
653,
16,
1377,
5371,
1042,
3065,
1042,
13,
1216,
21684,
225,
288,
565,
1139,
921,
8526,
707,
2615,
31,
565,
70... |
origDist.setSelected(true); distGroup.add(origDist); distGroup.add(unifDist); | public MatrixPanel() { m_rseed.setText("1"); origDist.setSelected(true); distGroup.add(origDist); distGroup.add(unifDist); /** Setting up GUI **/ m_selAttrib.addActionListener( new ActionListener() { public void actionPerformed(ActionEvent ae) { final JDialog jd = new JDialog((JFrame) MatrixPanel.this.getTopLevelAncestor(), "Attribute Selection Panel", true); JPanel jp = new JPanel(); JScrollPane js = new JScrollPane(m_attribList); JButton okBt = new JButton("OK"); JButton cancelBt = new JButton("Cancel"); final int [] savedSelection = m_attribList.getSelectedIndices(); okBt.addActionListener( new ActionListener() { public void actionPerformed(ActionEvent e) { jd.dispose(); } } ); cancelBt.addActionListener( new ActionListener() { public void actionPerformed(ActionEvent e) { m_attribList.setSelectedIndices(savedSelection); jd.dispose();} }); jd.addWindowListener( new WindowAdapter() { public void windowClosing(WindowEvent e) { m_attribList.setSelectedIndices(savedSelection); jd.dispose();} }); jp.add(okBt); jp.add(cancelBt); jd.getContentPane().add(js, BorderLayout.CENTER); jd.getContentPane().add(jp, BorderLayout.SOUTH); if(js.getPreferredSize().width < 200) jd.setSize( 250, 250 ); else jd.setSize( (int) js.getPreferredSize().width+10, 250); jd.setLocation( m_selAttrib.getLocationOnScreen().x, m_selAttrib.getLocationOnScreen().y-jd.getHeight() ); jd.setVisible(true); } }); m_updateBt.addActionListener( new ActionListener() { public void actionPerformed(ActionEvent e) { //m_selectedAttribs = m_attribList.getSelectedIndices(); initInternalFields(); Plot a = m_plotsPanel; a.setCellSize( m_plotSize.getValue() ); Dimension d = new Dimension((m_selectedAttribs.length)*(a.cellSize+a.extpad)+2, (m_selectedAttribs.length)*(a.cellSize+a.extpad)+2 ); //System.out.println("Size: "+a.cellSize+" Extpad: "+ // a.extpad+" selected: "+ // m_selectedAttribs.length+' '+d); a.setPreferredSize(d); a.setSize( a.getPreferredSize() ); a.setJitter( m_jitter.getValue() ); m_js.revalidate(); m_cp.setColours(m_colorList); m_cp.setCindex(m_classIndex); repaint(); } }); m_updateBt.setPreferredSize( m_selAttrib.getPreferredSize() ); m_plotSize.addChangeListener( new ChangeListener() { public void stateChanged(ChangeEvent ce) { m_plotSizeLb.setText("PlotSize: ["+m_plotSize.getValue()+"]"); m_plotSizeLb.setPreferredSize( m_plotLBSizeD ); m_jitter.setMaximum( m_plotSize.getValue()/5 ); //20% of cell Size } }); m_pointSize.addChangeListener( new ChangeListener() { public void stateChanged(ChangeEvent ce) { m_pointSizeLb.setText("PointSize: ["+m_pointSize.getValue()+"]"); m_pointSizeLb.setPreferredSize( m_pointLBSizeD ); datapointSize = m_pointSize.getValue(); } }); m_resampleBt.addActionListener( new ActionListener() { public void actionPerformed(ActionEvent e) { JLabel rseedLb = new JLabel("Random Seed: "); JTextField rseedTxt = m_rseed; JLabel percentLb = new JLabel("Subsample as"); JLabel percent2Lb = new JLabel("% of input: "); final JTextField percentTxt = new JTextField(5); percentTxt.setText( m_resamplePercent.getText() ); JButton doneBt = new JButton("Done"); final JDialog jd = new JDialog((JFrame) MatrixPanel.this.getTopLevelAncestor(), "Attribute Selection Panel", true) { public void dispose() { m_resamplePercent.setText(percentTxt.getText()); super.dispose(); } }; jd.setDefaultCloseOperation( JDialog.DISPOSE_ON_CLOSE ); doneBt.addActionListener( new ActionListener(){ public void actionPerformed(ActionEvent ae) { jd.dispose(); } }); GridBagLayout gbl = new GridBagLayout(); GridBagConstraints gbc = new GridBagConstraints(); JPanel p1 = new JPanel( gbl ); gbc.anchor = gbc.WEST; gbc.fill = gbc.HORIZONTAL; gbc.insets = new Insets(0,2,2,2); gbc.gridwidth = gbc.RELATIVE; p1.add(rseedLb, gbc); gbc.weightx = 0; gbc.gridwidth = gbc.REMAINDER; gbc.weightx=1; p1.add(rseedTxt, gbc); gbc.insets = new Insets(8,2,0,2); gbc.weightx=0; p1.add(percentLb, gbc); gbc.insets = new Insets(0,2,2,2); gbc.gridwidth = gbc.RELATIVE; p1.add(percent2Lb, gbc); gbc.gridwidth = gbc.REMAINDER; gbc.weightx=1; p1.add(percentTxt, gbc); gbc.insets = new Insets(8,2,2,2); if(m_data.attribute(m_classAttrib.getSelectedIndex()).isNominal()) { JPanel p2 = new JPanel( gbl ); p2.add(origDist, gbc); p2.add(unifDist, gbc); p2.setBorder( BorderFactory.createTitledBorder("Class Distribution") ); p1.add(p2, gbc); } JPanel p3 = new JPanel( gbl ); gbc.fill = gbc.HORIZONTAL; gbc.gridwidth = gbc.REMAINDER; gbc.weightx = 1; gbc.weighty = 0; p3.add(p1, gbc); gbc.insets = new Insets(8,4,8,4); p3.add(doneBt, gbc); jd.getContentPane().setLayout( new BorderLayout() ); jd.getContentPane().add(p3, BorderLayout.NORTH); jd.pack(); jd.setLocation( m_resampleBt.getLocationOnScreen().x, m_resampleBt.getLocationOnScreen().y-jd.getHeight() ); jd.setVisible(true); } }); optionsPanel = new JPanel( new GridBagLayout() ); //all the rest of the panels are in here. final JPanel p2 = new JPanel( new BorderLayout() ); //this has class colour panel final JPanel p3 = new JPanel( new GridBagLayout() ); //this has update and select buttons final JPanel p4 = new JPanel( new GridBagLayout() ); //this has the slider bars and combobox GridBagConstraints gbc = new GridBagConstraints(); m_plotLBSizeD = m_plotSizeLb.getPreferredSize(); m_pointLBSizeD = m_pointSizeLb.getPreferredSize(); m_pointSizeLb.setText("PointSize: [1]"); m_pointSizeLb.setPreferredSize( m_pointLBSizeD ); m_resampleBt.setPreferredSize( m_selAttrib.getPreferredSize() ); gbc.fill = gbc.HORIZONTAL; gbc.anchor = gbc.NORTHWEST; gbc.insets = new Insets(2,2,2,2); p4.add(m_plotSizeLb, gbc); gbc.weightx=1; gbc.gridwidth = gbc.REMAINDER; p4.add(m_plotSize, gbc); gbc.weightx=0; gbc.gridwidth = gbc.RELATIVE; p4.add(m_pointSizeLb, gbc); gbc.weightx=1; gbc.gridwidth = gbc.REMAINDER; p4.add(m_pointSize, gbc); gbc.weightx=0; gbc.gridwidth = gbc.RELATIVE; p4.add( new JLabel("Jitter: "), gbc); gbc.weightx=1; gbc.gridwidth = gbc.REMAINDER; p4.add(m_jitter, gbc); p4.add(m_classAttrib, gbc); gbc.gridwidth = gbc.REMAINDER; gbc.weightx=1; gbc.fill = gbc.NONE; p3.add(m_updateBt, gbc); p3.add(m_selAttrib, gbc); gbc.gridwidth = gbc.RELATIVE; gbc.weightx = 0; gbc.fill = gbc.VERTICAL; gbc.anchor = gbc.WEST; p3.add(m_resampleBt, gbc); gbc.gridwidth = gbc.REMAINDER; p3.add(m_resamplePercent, gbc); p2.setBorder(BorderFactory.createTitledBorder("Class Colour")); p2.add(m_cp, BorderLayout.SOUTH); gbc.insets = new Insets(8,5,2,5); gbc.anchor = gbc.SOUTHWEST; gbc.fill = gbc.HORIZONTAL; gbc.weightx=1; gbc.gridwidth = gbc.RELATIVE; optionsPanel.add(p4, gbc); gbc.gridwidth = gbc.REMAINDER; optionsPanel.add(p3, gbc); optionsPanel.add(p2, gbc); this.addComponentListener( new ComponentAdapter() { public void componentResized(ComponentEvent cv) { m_js.setMinimumSize( new Dimension(MatrixPanel.this.getWidth(), MatrixPanel.this.getHeight() -optionsPanel.getPreferredSize().height-10)); jp.setDividerLocation( MatrixPanel.this.getHeight()-optionsPanel.getPreferredSize().height-10 ); } }); optionsPanel.setMinimumSize( new Dimension(0,0) ); jp = new JSplitPane(JSplitPane.VERTICAL_SPLIT, m_js, optionsPanel); jp.setOneTouchExpandable(true); jp.setResizeWeight(1); this.setLayout( new BorderLayout() ); this.add(jp, BorderLayout.CENTER); /** Setting up the initial color list **/ for(int i=0; i<m_defaultColors.length-1; i++) m_colorList.addElement(m_defaultColors[i]); /** Initializing internal fields and components **/ m_selectedAttribs = m_attribList.getSelectedIndices(); m_plotsPanel = new Plot(); m_plotsPanel.setLayout(null); m_js.getHorizontalScrollBar().setUnitIncrement( 10 ); m_js.getVerticalScrollBar().setUnitIncrement( 10 ); m_js.setViewportView( m_plotsPanel ); m_js.setColumnHeaderView( m_plotsPanel.getColHeader() ); m_js.setRowHeaderView( m_plotsPanel.getRowHeader() ); final JLabel lb = new JLabel(" Plot Matrix"); lb.setFont(f); lb.setForeground(fontColor); lb.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER); m_js.setCorner(JScrollPane.UPPER_LEFT_CORNER, lb); m_cp.setInstances(m_data); m_cp.setBorder(BorderFactory.createEmptyBorder(15,10,10,10)); m_cp.addRepaintNotify(m_plotsPanel); //m_updateBt.doClick(); //not until setting up the instances } | 6866 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6866/71e412b065fbbc996f5d3e8ae36b547470e0a039/MatrixPanel.java/buggy/gui/visualize/MatrixPanel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
7298,
5537,
1435,
288,
565,
312,
67,
86,
12407,
18,
542,
1528,
2932,
21,
8863,
565,
1647,
5133,
18,
542,
7416,
12,
3767,
1769,
565,
2411,
1114,
18,
1289,
12,
4949,
5133,
1769,
565... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
7298,
5537,
1435,
288,
565,
312,
67,
86,
12407,
18,
542,
1528,
2932,
21,
8863,
565,
1647,
5133,
18,
542,
7416,
12,
3767,
1769,
565,
2411,
1114,
18,
1289,
12,
4949,
5133,
1769,
565... | |
String outflag = null; String outputPrefix = null; | protected void addRule(String relativePath, StringBuffer buffer, IResource resource) { String rule = null; String cmd = null; String buildFlags = null; String inputExtension = null; String outputExtension = null; // Is there a special rule for this file if (false) { } else { // Get the extension of the resource inputExtension = resource.getFileExtension(); // ASk the build model what it will produce from this outputExtension = info.getOutputExtension(inputExtension); /* * Create the pattern rule in the format * <relative_path>/%.o: $(ROOT)/<relative_path>/%.cpp * $(CC) $(CFLAGS) $(OUTPUT_FLAG) $@ $< * * Note that CC CFLAGS and OUTPUT_FLAG all come from the build model * and are resolved to a real command before writing to the module * makefile, so a real command might look something like * source1/%.o: $(ROOT)/source1/%.cpp * g++ -g -O2 -c -I/cygdrive/c/eclipse/workspace/Project/headers -o $@ $< */ rule = relativePath + WILDCARD + DOT + outputExtension + COLON + WHITESPACE + "$(ROOT)" + SEPARATOR + relativePath + WILDCARD + DOT + inputExtension; } // Check if the rule is listed as something we already generated in the makefile if (!getRuleList().contains(rule)) { // Add it to the list getRuleList().add(rule); // Add the rule and command to the makefile buffer.append(rule + NEWLINE); cmd = info.getToolForSource(inputExtension); buildFlags = info.getFlagsForSource(inputExtension); buffer.append(TAB + cmd + WHITESPACE + buildFlags + WHITESPACE + "$(OUTPUT_FLAG) $@" + WHITESPACE + "$<" + NEWLINE + NEWLINE); } } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/3a2ed3957a53250c08f7c378f74506da58999e8a/MakefileGenerator.java/clean/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/core/MakefileGenerator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
780,
596,
6420,
273,
446,
31,
514,
876,
2244,
273,
446,
31,
225,
918,
780,
596,
6420,
273,
446,
31,
514,
876,
2244,
273,
446,
31,
225,
21264,
12,
780,
780,
596,
6420,
273,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
780,
596,
6420,
273,
446,
31,
514,
876,
2244,
273,
446,
31,
225,
918,
780,
596,
6420,
273,
446,
31,
514,
876,
2244,
273,
446,
31,
225,
21264,
12,
780,
780,
596,
6420,
273,
... | |
localNames.increaseBlockLevel(); | localNames.setBlockLevel(localNames.getBlockLevel() + 1); | public void push(StackElement newElement) { localNames.increaseBlockLevel(); super.push(newElement); } | 45221 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45221/bfbf574a72dd640d8cff4544774a0d26a18665d8/BlockNamesStack.java/clean/src/org/jruby/parser/BlockNamesStack.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1817,
12,
2624,
1046,
31308,
13,
288,
3639,
1191,
1557,
18,
542,
1768,
2355,
12,
3729,
1557,
18,
588,
1768,
2355,
1435,
397,
404,
1769,
3639,
2240,
18,
6206,
12,
2704,
1046,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1817,
12,
2624,
1046,
31308,
13,
288,
3639,
1191,
1557,
18,
542,
1768,
2355,
12,
3729,
1557,
18,
588,
1768,
2355,
1435,
397,
404,
1769,
3639,
2240,
18,
6206,
12,
2704,
1046,
... |
if ( isActive( ) ) | if ( isActive( ) && event.getAction( ) != ActivityStackEvent.ROLL_BACK ) | private ActivityStackListener getCommandStackListener( ) { if ( commandStackListener == null ) { commandStackListener = new ActivityStackListener( ) { public void stackChanged( ActivityStackEvent event ) { if ( isActive( ) ) { reloadEditorInput( ); } } }; } return commandStackListener; } | 5230 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5230/0891eac94d79e1ccdc45848f6b4cd34ac5ebf5bd/ReportXMLSourceEditorFormPage.java/clean/UI/org.eclipse.birt.report.designer.ui.editor.xml.wtp/src/org/eclipse/birt/report/designer/ui/editor/pages/xml/ReportXMLSourceEditorFormPage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
9621,
2624,
2223,
12856,
2624,
2223,
12,
262,
202,
95,
202,
202,
430,
261,
1296,
2624,
2223,
422,
446,
262,
202,
202,
95,
1082,
202,
3076,
2624,
2223,
273,
394,
9621,
2624,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
9621,
2624,
2223,
12856,
2624,
2223,
12,
262,
202,
95,
202,
202,
430,
261,
1296,
2624,
2223,
422,
446,
262,
202,
202,
95,
1082,
202,
3076,
2624,
2223,
273,
394,
9621,
2624,
2... |
return Collections.EMPTY_LIST; | return EMPTY_LIST; | public List childNodes() { return Collections.EMPTY_LIST; } | 46258 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46258/b1293eda8454686e846e2a9837b348e2983bb423/FloatNode.java/clean/src/org/jruby/ast/FloatNode.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
987,
10582,
1435,
288,
3639,
327,
8984,
67,
7085,
31,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
987,
10582,
1435,
288,
3639,
327,
8984,
67,
7085,
31,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
String url = "http: | public void testNoContentHashedDifferentThan0Content() throws IOException { String url = "http://www.example.com"; MockCachedUrlSet cus = new MockCachedUrlSet(TEST_URL_BASE); cus.addUrl("", TEST_URL_BASE, false, true); cus.setTreeItSource(new ArrayList()); GenericContentHasher hasher = new GenericContentHasher(cus, dig); hashToEnd(hasher, 10); MockMessageDigest dig2 = new MockMessageDigest(); cus = new MockCachedUrlSet(TEST_URL_BASE); cus.addUrl("", TEST_URL_BASE, true, true); cus.setTreeItSource(new ArrayList()); hasher = new GenericContentHasher(cus, dig2); hashToEnd(hasher, 15); assertNotEquals(dig, dig2); } | 8150 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8150/8d493a11db22a4db627941f321123ea8a926d0df/TestGenericContentHasher.java/clean/test/src/org/lockss/hasher/TestGenericContentHasher.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
1842,
2279,
1350,
2310,
329,
26270,
9516,
20,
1350,
1435,
1216,
1860,
288,
565,
514,
880,
273,
315,
2505,
2207,
5591,
18,
8236,
18,
832,
14432,
565,
7867,
9839,
1489,
694,
2796... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2279,
1350,
2310,
329,
26270,
9516,
20,
1350,
1435,
1216,
1860,
288,
565,
514,
880,
273,
315,
2505,
2207,
5591,
18,
8236,
18,
832,
14432,
565,
7867,
9839,
1489,
694,
2796... | |
throw new BuildException( "instrumentdir attribute must be set!", location ); | throw new BuildException("instrumentdir attribute must be set!", location); | private void preconditions() throws BuildException { if (srcDir == null) { throw new BuildException( "srcdir attribute must be set!", location ); } if (!srcDir.exists()) { throw new BuildException( "srcdir \"" + srcDir.getPath() + "\" does not exist!", location ); } if (instrumentDir == null) { throw new BuildException( "instrumentdir attribute must be set!", location ); } if (repositoryDir == null) { throw new BuildException( "repositorydir attribute must be set!", location ); } if (updateIcontrol == true && classDir == null) { throw new BuildException( "classdir attribute must be specified when updateicontrol=true!", location ); } if( updateIcontrol == true && controlFile == null ) { throw new BuildException( "controlfile attribute must be specified when updateicontrol=true!", location ); } } | 17033 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/17033/c7b5b643b25b20f5c96097b2c54e2e26a054f212/IContract.java/clean/src/main/org/apache/tools/ant/taskdefs/optional/IContract.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
675,
6381,
1435,
1216,
18463,
288,
3639,
309,
261,
4816,
1621,
422,
446,
13,
288,
5411,
604,
394,
18463,
12,
315,
4816,
1214,
1566,
1297,
506,
444,
5,
3113,
2117,
11272,
3639,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
675,
6381,
1435,
1216,
18463,
288,
3639,
309,
261,
4816,
1621,
422,
446,
13,
288,
5411,
604,
394,
18463,
12,
315,
4816,
1214,
1566,
1297,
506,
444,
5,
3113,
2117,
11272,
3639,
... |
shutdownEvent = new Notification(); shutdownEvent.putAttribute(SienaConstants.AI2TV_CLIENT_SHUTDOWN, ""); publishNotification(shutdownEvent); | shutdownEvent = new Notification(); shutdownEvent.putAttribute(SienaConstants.AI2TV_CLIENT_SHUTDOWN, ""); publishNotification(shutdownEvent); | void shutdown(){ Client.debug.println("Shutting down CommController"); Client.debug.println("Unsubscribing to Siena server"); try { Notification shutdownEvent = new Notification(); shutdownEvent.putAttribute(SienaConstants.REMOVE_USER_FROM_VSID, "FOO"); publishNotification(shutdownEvent); shutdownEvent = new Notification(); shutdownEvent.putAttribute(SienaConstants.AI2TV_CLIENT_SHUTDOWN, ""); publishNotification(shutdownEvent); Filter filter = new Filter(); filter.addConstraint(SienaConstants.AI2TV_VIDEO_ACTION, Op.ANY, "FOO"); _siena.unsubscribe(filter, this); filter = new Filter(); filter.addConstraint(SienaConstants.GET_ACTIVE_VSIDS_REPLY, Op.ANY, "FOO"); _siena.unsubscribe(filter, this); filter = new Filter(); filter.addConstraint(SienaConstants.JOIN_NEW_VSID_REPLY, Op.ANY, "FOO"); _siena.unsubscribe(filter, this); } catch (siena.SienaException e) { Client.err.println("error:" + e); } Client.debug.println("Shutting down Siena server"); _siena.shutdown(); _isActive = false; } | 14573 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/14573/0ea120c2300a4d37204f3efda12945c1671f15c6/CommController.java/clean/client/CommController.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
918,
5731,
1435,
95,
377,
2445,
18,
4148,
18,
8222,
2932,
1555,
25387,
2588,
16854,
2933,
8863,
565,
2445,
18,
4148,
18,
8222,
2932,
984,
1717,
4091,
310,
358,
27834,
24457,
1438,
8863,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
918,
5731,
1435,
95,
377,
2445,
18,
4148,
18,
8222,
2932,
1555,
25387,
2588,
16854,
2933,
8863,
565,
2445,
18,
4148,
18,
8222,
2932,
984,
1717,
4091,
310,
358,
27834,
24457,
1438,
8863,
5... |
double capacity = 0; | public double calc(PeerProfile profile) { double capacity = 0; RateStat acceptStat = profile.getTunnelCreateResponseTime(); RateStat rejectStat = profile.getTunnelHistory().getRejectionRate(); RateStat failedStat = profile.getTunnelHistory().getFailedRate(); capacity += estimatePartial(acceptStat, rejectStat, failedStat, 10*60*1000); capacity += estimatePartial(acceptStat, rejectStat, failedStat, 30*60*1000); capacity += estimatePartial(acceptStat, rejectStat, failedStat, 60*60*1000); capacity += estimatePartial(acceptStat, rejectStat, failedStat, 24*60*60*1000); if (tooOld(profile)) capacity = 1; capacity += profile.getReliabilityBonus(); return capacity; } | 3808 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3808/9e16bc203acad926f1d4c7750311694f35c88100/CapacityCalculator.java/buggy/router/java/src/net/i2p/router/peermanager/CapacityCalculator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1645,
7029,
12,
6813,
4029,
3042,
13,
288,
8227,
13025,
5000,
2791,
5000,
273,
3042,
18,
588,
20329,
1684,
1064,
950,
5621,
3639,
13025,
5000,
4925,
5000,
273,
3042,
18,
588,
20329,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1645,
7029,
12,
6813,
4029,
3042,
13,
288,
8227,
13025,
5000,
2791,
5000,
273,
3042,
18,
588,
20329,
1684,
1064,
950,
5621,
3639,
13025,
5000,
4925,
5000,
273,
3042,
18,
588,
20329,
... | |
loa[2].set( x2 + kError + dTapeWidth, zeroLocation ); | loa[2].set( x2 + kError + dTapeWidth, zeroLocation - dTapeWidth ); | private final void plotPlane( IPrimitiveRenderer ipr, double x1, double y1, double x2, double y2, double z1, double z2, boolean drawSide, boolean leftSide ) throws ChartException { if ( bRendering3D ) { final Polygon3DRenderEvent pre = (Polygon3DRenderEvent) ( (EventObjectCache) ipr ).getEventObject( oSource, Polygon3DRenderEvent.class ); pre.setOutline( null ); pre.setDoubleSided( true ); pre.setBackground( tapeColor ); if ( !leftSide ) { loa3d[0].set( x1 + kError, y1 + kError, z1 ); loa3d[1].set( x2 + kError, y2 + kError, z2 ); loa3d[2].set( x2 + kError, y2 + kError, z2 - dTapeWidth ); loa3d[3].set( x1 + kError, y1 + kError, z1 - dTapeWidth ); pre.setPoints3D( loa3d ); dc.addPlane( pre, PrimitiveRenderEvent.FILL ); } if ( drawSide ) { pre.setBackground( sideColor ); if ( leftSide ) { if ( y1 + kError > zeroLocation ) { loa3d[0].set( x1 + kError, y1 + kError, z1 ); loa3d[1].set( x1 + kError, y1 + kError, z1 - dTapeWidth ); loa3d[2].set( x1 + kError, zeroLocation, z1 - dTapeWidth ); loa3d[3].set( x1 + kError, zeroLocation, z1 ); } else { loa3d[0].set( x1 + kError, y1 + kError, z1 ); loa3d[1].set( x1 + kError, zeroLocation, z1 ); loa3d[2].set( x1 + kError, zeroLocation, z1 - dTapeWidth ); loa3d[3].set( x1 + kError, y1 + kError, z1 - dTapeWidth ); } } else { if ( y2 + kError > zeroLocation ) { loa3d[0].set( x2 + kError, y2 + kError, z2 ); loa3d[1].set( x2 + kError, zeroLocation, z2 ); loa3d[2].set( x2 + kError, zeroLocation, z2 - dTapeWidth ); loa3d[3].set( x2 + kError, y2 + kError, z2 - dTapeWidth ); } else { loa3d[0].set( x2 + kError, y2 + kError, z2 ); loa3d[1].set( x2 + kError, y2 + kError, z2 - dTapeWidth ); loa3d[2].set( x2 + kError, zeroLocation, z2 - dTapeWidth ); loa3d[3].set( x2 + kError, zeroLocation, z2 ); } } pre.setPoints3D( loa3d ); dc.addPlane( pre, PrimitiveRenderEvent.FILL ); } } else { final PolygonRenderEvent pre = (PolygonRenderEvent) ( (EventObjectCache) ipr ).getEventObject( oSource, PolygonRenderEvent.class ); pre.setOutline( null ); pre.setBackground( tapeColor ); loa[0].set( x1 + kError, y1 + kError ); loa[1].set( x2 + kError, y2 + kError ); loa[2].set( x2 + kError + dTapeWidth, y2 + kError - dTapeWidth ); loa[3].set( x1 + kError + dTapeWidth, y1 + kError - dTapeWidth ); pre.setPoints( loa ); if ( bDeferred ) { dc.addPlane( pre, PrimitiveRenderEvent.FILL ); } else { ipr.fillPolygon( pre ); } if ( drawSide ) { pre.setBackground( sideColor ); if ( leftSide ) { loa[0].set( x1 + kError, y1 + kError ); loa[1].set( x1 + kError + dTapeWidth, y1 + kError - dTapeWidth ); if ( cwa.isTransposed( ) ) { loa[2].set( zeroLocation, y1 + kError - dTapeWidth ); loa[3].set( zeroLocation, y1 + kError ); } else { loa[2].set( x1 + kError + dTapeWidth, zeroLocation ); loa[3].set( x1 + kError, zeroLocation ); } } else { loa[0].set( x2 + kError, y2 + kError ); loa[1].set( x2 + kError + dTapeWidth, y2 + kError - dTapeWidth ); if ( cwa.isTransposed( ) ) { loa[2].set( zeroLocation, y2 + kError - dTapeWidth ); loa[3].set( zeroLocation, y2 + kError ); } else { loa[2].set( x2 + kError + dTapeWidth, zeroLocation ); loa[3].set( x2 + kError, zeroLocation ); } } pre.setPoints( loa ); if ( bDeferred ) { dc.addPlane( pre, PrimitiveRenderEvent.FILL ); } else { ipr.fillPolygon( pre ); } } } } | 46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/855985a2779527c3517f5dc48c3079e69bb4c3a2/CurveRenderer.java/clean/chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/render/CurveRenderer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
727,
918,
3207,
19505,
12,
467,
9840,
6747,
277,
683,
16,
1645,
619,
21,
16,
1645,
677,
21,
16,
1082,
202,
9056,
619,
22,
16,
1645,
677,
22,
16,
1645,
998,
21,
16,
1645,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
727,
918,
3207,
19505,
12,
467,
9840,
6747,
277,
683,
16,
1645,
619,
21,
16,
1645,
677,
21,
16,
1082,
202,
9056,
619,
22,
16,
1645,
677,
22,
16,
1645,
998,
21,
16,
1645,
... |
return ch != -1 && Character.isUnicodeIdentifierPart( (char)ch ); } | return ch != -1 && Character.isUnicodeIdentifierPart((char)ch); } | private boolean isIdentifierPart( int ch ) { return ch != -1 && Character.isUnicodeIdentifierPart( (char)ch ); } | 54028 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54028/4aaf60d8fa76687c3492c508dd98678fbbd3d935/Lexer.java/buggy/jmock/examples/calculator/src/org/jmock/examples/calculator/Lexer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1250,
353,
3004,
1988,
12,
509,
462,
262,
288,
3639,
327,
462,
480,
300,
21,
597,
6577,
18,
291,
16532,
3004,
1988,
12,
261,
3001,
13,
343,
11272,
565,
289,
2,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
1250,
353,
3004,
1988,
12,
509,
462,
262,
288,
3639,
327,
462,
480,
300,
21,
597,
6577,
18,
291,
16532,
3004,
1988,
12,
261,
3001,
13,
343,
11272,
565,
289,
2,
-100,
-100,
-100,
... |
if (m_upProcessingThread == null) { | if(m_upProcessingThread == null) { | public synchronized void resume() { if (m_upProcessingThread == null) { startProcessingThreads(); } m_upLatch.unlock(); } | 3550 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3550/595c1743692efa6e4226a77afcc832561ea81eb9/MessageDispatcher.java/clean/src/org/jgroups/blocks/MessageDispatcher.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
3852,
918,
10774,
1435,
288,
5411,
309,
12,
81,
67,
416,
7798,
3830,
422,
446,
13,
288,
7734,
787,
7798,
13233,
5621,
5411,
289,
5411,
312,
67,
416,
23463,
18,
26226,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
1071,
3852,
918,
10774,
1435,
288,
5411,
309,
12,
81,
67,
416,
7798,
3830,
422,
446,
13,
288,
7734,
787,
7798,
13233,
5621,
5411,
289,
5411,
312,
67,
416,
23463,
18,
26226,
5621,
3639,
... |
FileReader fr = new FileReader(gpPropertiesFile); char buf[] = new char[(int)gpPropertiesFile.length()]; int len = fr.read(buf, 0, buf.length); fr.close(); String properties = new String(buf, 0, len); return properties; | return readPropertiesFile(gpPropertiesFile); | public static String readGenePatternProperties() throws IOException { File gpPropertiesFile = new File(System.getProperty("resources"), "genepattern.properties"); FileReader fr = new FileReader(gpPropertiesFile); char buf[] = new char[(int)gpPropertiesFile.length()]; int len = fr.read(buf, 0, buf.length); fr.close(); String properties = new String(buf, 0, len); return properties; } | 57344 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57344/a18c1c6cf9b164fc6bcf0c8c8d8f66068a488fd9/GenePatternAnalysisTask.java/clean/src/org/genepattern/server/genepattern/GenePatternAnalysisTask.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
514,
855,
24442,
3234,
2297,
1435,
1216,
1860,
288,
202,
202,
812,
4178,
2297,
812,
273,
394,
1387,
12,
3163,
18,
588,
1396,
2932,
4683,
6,
3631,
315,
4507,
881,
1344,
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,
760,
514,
855,
24442,
3234,
2297,
1435,
1216,
1860,
288,
202,
202,
812,
4178,
2297,
812,
273,
394,
1387,
12,
3163,
18,
588,
1396,
2932,
4683,
6,
3631,
315,
4507,
881,
1344,
18... |
public int getColumnNumber() { //return fCurrentEntity != null ? fCurrentEntity.columnNumber : -1; if (fCurrentEntity != null) { if (fCurrentEntity.entityLocation != null && fCurrentEntity.entityLocation.getLiteralSystemId() != null ) { return fCurrentEntity.columnNumber; } else { // search for the first external entity on the stack int size = fEntityStack.size(); for (int i=size-1; i>0 ; i--) { ScannedEntity firstExternalEntity = (ScannedEntity)fEntityStack.elementAt(i); if (firstExternalEntity.entityLocation != null && firstExternalEntity.entityLocation.getLiteralSystemId() != null) { return firstExternalEntity.columnNumber; } } } } return -1; } // getColumnNumber():int | 4434 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4434/6c6b759ff83740e6520ce4c736f1e7d9cf99a7c0/XMLEntityManager.java/clean/src/org/apache/xerces/impl/XMLEntityManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1071,
474,
588,
1494,
1854,
1435,
95,
759,
2463,
74,
3935,
1943,
5,
33,
2011,
35,
74,
3935,
1943,
18,
2827,
1854,
30,
17,
21,
31,
430,
12,
74,
3935,
1943,
5,
33,
2011,
15329,
430,
12,
74... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
474,
588,
1494,
1854,
1435,
95,
759,
2463,
74,
3935,
1943,
5,
33,
2011,
35,
74,
3935,
1943,
18,
2827,
1854,
30,
17,
21,
31,
430,
12,
74,
3935,
1943,
5,
33,
2011,
15329,
430,
12,
74... | ||
public void testIsAdmin() { Message message = new Message(); message.getHeader().setString(MsgType.FIELD, MsgType.HEARTBEAT); assertTrue(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.LOGON); assertTrue(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.LOGOUT); assertTrue(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.SEQUENCE_RESET); assertTrue(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.RESEND_REQUEST); assertTrue(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.TEST_REQUEST); assertTrue(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.REJECT); assertTrue(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.ORDER_SINGLE); assertFalse(message.isAdmin()); message.getHeader().setString(MsgType.FIELD, MsgType.QUOTE_RESPONSE); assertFalse(message.isAdmin()); } | 6791 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6791/687565539d84115c31e47580ebda99933142832e/MessageTest.java/buggy/core/src/test/java/quickfix/MessageTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
2520,
4446,
1435,
288,
3639,
2350,
883,
273,
394,
2350,
5621,
3639,
883,
18,
588,
1864,
7675,
542,
780,
12,
3332,
559,
18,
6776,
16,
8671,
559,
18,
3900,
4928,
5948,
78... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
2520,
4446,
1435,
288,
3639,
2350,
883,
273,
394,
2350,
5621,
3639,
883,
18,
588,
1864,
7675,
542,
780,
12,
3332,
559,
18,
6776,
16,
8671,
559,
18,
3900,
4928,
5948,
78... | ||
412, 412, 0, 412, 412, 412, 412, 412, 0, 469, 334, 0, 469, 469, 469, 469, 469, 469, 469, 469, 0, 469, 469, 469, 469, 0, 0, 469, 469, 469, | 412, 412, 0, 412, 412, 412, 412, 412, 334, 469, 0, 0, 469, 469, 469, 469, 469, 469, 469, 469, 0, 469, 469, 469, 469, 0, 469, 469, 469, 412, | private static final short[] yyTable1() { return new short[] { 234, 234, 391, 229, 234, 203, 419, 239, 239, 189, 580, 239, 237, 237, 248, 564, 237, 814, 190, 190, 591, 601, 252, 240, 240, 203, 519, 240, 257, 259, 216, 95, 782, 552, 234, 234, 216, 283, 284, 190, 253, 617, 274, 356, 249, 461, 732, 652, 265, 466, 492, 109, 109, 551, 300, 442, 281, 291, 275, 435, 337, 109, 362, 492, 337, 442, 190, 660, 661, 422, 62, 588, 221, 215, 218, 617, 423, 424, 783, 217, 786, 492, 469, 387, 382, 217, 606, 353, 244, 441, 60, 362, 362, 248, 393, 342, 394, 362, 109, 444, 253, 285, 79, 79, 110, 110, 353, 69, 79, 210, 210, 210, 492, 492, 225, 210, 210, 354, 492, 210, 235, 235, 455, 247, 235, 455, 210, 69, 492, 70, 309, 363, 221, 442, 455, 656, 247, 109, 649, 216, 492, 71, 338, 470, 387, 535, 338, 79, 210, 210, 253, 279, 360, 210, 269, 492, 361, 216, 61, 324, 230, 492, 492, 326, 327, 261, 657, 447, 782, 366, 308, 492, 262, 579, 264, 394, 89, 492, 492, 363, 363, 456, 457, 458, 456, 457, 460, 598, 217, 492, 279, 230, 40, 456, 457, 462, 260, 261, 492, 564, 356, 392, 455, 291, 492, 210, 217, 79, 684, 438, 87, 440, 190, 391, 856, 64, 234, 234, 284, 308, 653, 492, 716, 40, 89, 89, 217, 256, 691, 234, 67, 234, 234, 441, 264, 64, 239, 369, 239, 420, 65, 237, 771, 237, 237, 55, 492, 492, 356, 356, 67, 335, 240, 439, 240, 240, 487, 273, 87, 87, 65, 456, 457, 465, 265, 295, 307, 308, 242, 345, 492, 243, 391, 391, 391, 387, 363, 402, 346, 221, 343, 297, 441, 492, 762, 397, 398, 344, 487, 766, 481, 278, 481, 381, 479, 480, 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, 498, 499, 500, 501, 502, 503, 504, 307, 308, 210, 210, 550, 455, 494, 234, 387, 471, 524, 527, 492, 234, 476, 340, 347, 538, 531, 482, 531, 482, 341, 406, 210, 69, 210, 210, 802, 235, 265, 235, 417, 518, 234, 536, 79, 494, 617, 348, 626, 629, 234, 79, 617, 472, 473, 474, 475, 531, 492, 492, 234, 524, 589, 538, 61, 364, 492, 234, 518, 642, 721, 429, 456, 457, 594, 234, 363, 741, 264, 234, 234, 525, 528, 234, 532, 109, 518, 620, 539, 79, 210, 210, 210, 210, 79, 210, 210, 492, 597, 622, 634, 518, 492, 614, 564, 637, 638, 639, 632, 627, 624, 203, 543, 69, 234, 841, 628, 234, 376, 839, 234, 89, 352, 825, 492, 190, 454, 234, 377, 835, 210, 518, 492, 210, 210, 269, 210, 79, 279, 459, 210, 64, 492, 492, 61, 356, 600, 600, 511, 516, 363, 522, 523, 518, 379, 87, 67, 210, 79, 210, 40, 40, 269, 492, 264, 367, 65, 79, 617, 380, 459, 79, 368, 492, 389, 210, 549, 855, 792, 79, 269, 79, 441, 687, 413, 273, 415, 418, 459, 381, 210, 492, 273, 511, 516, 269, 617, 670, 582, 234, 673, 675, 210, 385, 445, 400, 590, 861, 592, 549, 386, 217, 401, 441, 278, 533, 79, 455, 396, 278, 388, 64, 666, 463, 492, 492, 278, 671, 307, 308, 670, 473, 390, 674, 676, 445, 67, 403, 445, 549, 357, 358, 210, 635, 576, 688, 65, 269, 381, 381, 381, 562, 563, 445, 190, 63, 430, 701, 71, 454, 203, 549, 411, 431, 81, 445, 234, 448, 449, 837, 399, 309, 94, 94, 190, 61, 456, 457, 94, 94, 94, 94, 709, 579, 234, 94, 94, 406, 234, 94, 454, 682, 234, 454, 492, 683, 94, 492, 492, 82, 324, 293, 294, 234, 326, 327, 328, 329, 454, 74, 407, 273, 410, 426, 372, 692, 744, 94, 94, 94, 778, 373, 428, 94, 434, 309, 614, 432, 752, 433, 446, 436, 210, 79, 229, 758, 760, 437, 450, 451, 464, 763, 765, 492, 780, 468, 537, 82, 82, 540, 579, 768, 234, 79, 583, 394, 423, 596, 725, 608, 618, 630, 234, 631, 636, 640, 452, 79, 641, 833, 654, 813, 662, 453, 815, 94, 834, 94, 492, 663, 423, 668, 492, 492, 669, 758, 760, 763, 560, 561, 562, 563, 109, 234, 705, 210, 492, 672, 759, 761, 234, 492, 87, 492, 764, 234, 234, 679, 83, 83, 111, 111, 810, 680, 83, 673, 675, 809, 210, 88, 226, 210, 685, 740, 686, 689, 609, 693, 811, 695, 697, 699, 773, 702, 700, 737, 738, 109, 79, 706, 821, 712, 234, 713, 714, 225, 79, 715, 79, 79, 210, 210, 76, 83, 278, 76, 210, 280, 84, 717, 794, 278, 718, 720, 724, 746, 473, 88, 88, 821, 232, 234, 76, 755, 600, 756, 757, 845, 76, 727, 733, 234, 87, 84, 84, 234, 735, 736, 739, 84, 788, 743, 94, 94, 79, 228, 280, 210, 745, 89, 279, 767, 472, 822, 696, 698, 84, 84, 234, 79, 79, 79, 774, 83, 94, 775, 94, 94, 779, 160, 234, 793, 234, 795, 796, 472, 94, 797, 84, 807, 817, 818, 827, 94, 518, 816, 799, 800, 801, 472, 234, 819, 234, 868, 82, 820, 492, 492, 492, 829, 234, 273, 832, 492, 234, 210, 82, 842, 273, 79, 79, 843, 747, 748, 847, 749, 849, 852, 160, 41, 42, 94, 94, 94, 94, 94, 94, 94, 94, 89, 79, 853, 854, 873, 78, 871, 824, 875, 84, 91, 91, 112, 112, 112, 877, 91, 423, 492, 493, 481, 483, 230, 80, 423, 493, 483, 86, 836, 483, 485, 485, 254, 94, 492, 79, 94, 94, 487, 94, 94, 423, 487, 94, 210, 82, 79, 494, 423, 269, 299, 115, 473, 79, 874, 91, 75, 728, 188, 282, 94, 94, 94, 549, 339, 826, 690, 734, 754, 862, 279, 351, 421, 863, 94, 86, 86, 0, 94, 784, 864, 785, 94, 83, 94, 92, 92, 301, 153, 0, 83, 92, 0, 94, 0, 0, 0, 88, 282, 0, 0, 0, 0, 280, 0, 94, 0, 0, 473, 0, 0, 76, 472, 0, 0, 91, 0, 0, 0, 94, 0, 302, 303, 304, 305, 306, 0, 0, 83, 0, 92, 0, 0, 83, 84, 472, 84, 153, 828, 830, 0, 831, 0, 0, 0, 94, 0, 85, 0, 472, 208, 208, 208, 0, 0, 0, 0, 0, 84, 0, 0, 279, 0, 472, 0, 84, 0, 250, 279, 803, 472, 0, 805, 806, 0, 472, 83, 280, 270, 0, 555, 83, 0, 556, 557, 558, 472, 0, 0, 267, 92, 76, 0, 472, 472, 85, 85, 83, 472, 0, 472, 0, 0, 84, 0, 0, 0, 472, 84, 0, 83, 872, 472, 0, 84, 0, 0, 472, 83, 559, 83, 0, 0, 0, 560, 561, 562, 563, 476, 83, 83, 472, 0, 0, 160, 94, 94, 160, 160, 160, 86, 473, 0, 0, 0, 0, 359, 0, 0, 0, 0, 84, 0, 848, 850, 83, 94, 81, 88, 0, 81, 418, 280, 0, 91, 0, 0, 0, 418, 0, 94, 91, 84, 160, 0, 0, 0, 81, 160, 160, 160, 160, 0, 0, 86, 84, 0, 0, 865, 866, 0, 83, 473, 84, 870, 84, 0, 473, 94, 473, 0, 0, 0, 0, 473, 0, 0, 273, 0, 91, 279, 878, 0, 0, 91, 0, 163, 279, 0, 880, 86, 94, 882, 473, 94, 0, 884, 0, 0, 555, 84, 0, 556, 557, 558, 0, 0, 0, 88, 92, 0, 94, 0, 280, 0, 0, 92, 0, 473, 94, 280, 94, 94, 94, 94, 473, 0, 91, 282, 94, 473, 0, 0, 208, 208, 163, 0, 0, 0, 0, 0, 83, 83, 560, 561, 562, 563, 0, 91, 473, 0, 0, 153, 0, 92, 153, 153, 153, 0, 92, 0, 91, 83, 404, 405, 0, 0, 94, 0, 91, 94, 91, 0, 0, 85, 0, 83, 0, 0, 417, 0, 0, 94, 94, 94, 481, 417, 476, 0, 0, 0, 153, 0, 0, 148, 0, 153, 153, 153, 153, 0, 0, 92, 0, 0, 0, 91, 0, 83, 0, 0, 0, 0, 208, 208, 208, 208, 84, 477, 478, 0, 0, 0, 92, 0, 0, 481, 0, 94, 0, 0, 0, 94, 94, 0, 0, 92, 84, 476, 0, 0, 270, 0, 148, 92, 476, 92, 83, 751, 0, 472, 84, 0, 94, 226, 83, 0, 83, 83, 0, 0, 0, 0, 0, 0, 81, 0, 131, 270, 476, 0, 0, 280, 0, 0, 0, 575, 581, 530, 280, 534, 92, 553, 0, 77, 0, 270, 94, 0, 0, 0, 0, 0, 0, 0, 0, 94, 0, 94, 789, 0, 270, 0, 83, 0, 94, 0, 0, 0, 577, 481, 0, 0, 0, 0, 0, 131, 273, 83, 83, 83, 0, 84, 91, 273, 267, 530, 0, 0, 228, 84, 476, 84, 84, 0, 0, 0, 0, 610, 613, 0, 0, 616, 91, 0, 81, 623, 0, 0, 0, 0, 78, 0, 270, 78, 0, 0, 91, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 83, 83, 0, 78, 0, 644, 790, 0, 616, 0, 84, 644, 163, 0, 0, 163, 163, 163, 0, 0, 132, 83, 0, 0, 0, 84, 84, 84, 0, 0, 92, 0, 0, 473, 0, 0, 659, 659, 659, 419, 0, 0, 667, 0, 0, 79, 419, 0, 79, 0, 92, 163, 0, 667, 667, 83, 163, 163, 163, 163, 91, 0, 0, 0, 92, 79, 83, 230, 91, 132, 91, 91, 0, 83, 0, 84, 84, 667, 0, 481, 481, 481, 0, 0, 0, 481, 481, 208, 481, 0, 677, 0, 0, 0, 74, 278, 84, 74, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 704, 0, 708, 791, 581, 74, 0, 91, 0, 0, 80, 148, 581, 80, 148, 148, 148, 0, 0, 0, 0, 84, 91, 91, 91, 0, 92, 482, 0, 0, 80, 0, 84, 0, 92, 423, 92, 92, 420, 84, 0, 208, 85, 476, 0, 420, 0, 0, 719, 0, 148, 0, 0, 0, 0, 148, 148, 148, 148, 0, 279, 0, 0, 0, 0, 0, 726, 742, 482, 0, 729, 0, 91, 91, 730, 0, 0, 0, 0, 0, 0, 0, 92, 0, 131, 613, 0, 131, 131, 131, 0, 0, 412, 91, 476, 0, 0, 92, 92, 92, 0, 476, 412, 659, 0, 0, 472, 0, 0, 0, 0, 422, 78, 473, 0, 0, 0, 0, 422, 0, 0, 0, 85, 131, 0, 476, 0, 91, 131, 131, 131, 131, 0, 412, 770, 0, 412, 0, 91, 0, 0, 0, 0, 208, 777, 91, 0, 92, 92, 0, 412, 412, 482, 412, 0, 412, 0, 0, 0, 667, 667, 0, 0, 0, 473, 0, 0, 0, 92, 0, 0, 473, 0, 0, 79, 644, 473, 0, 0, 0, 0, 0, 616, 412, 0, 412, 0, 0, 616, 0, 0, 0, 78, 0, 0, 473, 0, 0, 0, 0, 0, 0, 92, 0, 0, 132, 0, 0, 132, 132, 132, 0, 0, 92, 0, 415, 0, 412, 0, 0, 92, 581, 0, 74, 823, 415, 278, 0, 0, 0, 0, 0, 421, 278, 0, 0, 0, 0, 473, 421, 0, 0, 0, 0, 132, 0, 0, 0, 80, 132, 132, 132, 132, 838, 79, 0, 415, 270, 0, 415, 0, 0, 0, 846, 0, 0, 0, 851, 0, 0, 0, 0, 0, 415, 415, 423, 415, 0, 415, 0, 0, 0, 423, 0, 0, 581, 0, 0, 253, 482, 482, 482, 0, 0, 0, 482, 482, 0, 482, 0, 279, 0, 613, 74, 616, 0, 415, 279, 415, 309, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 876, 0, 879, 322, 323, 0, 80, 0, 0, 0, 616, 0, 0, 0, 883, 0, 324, 0, 415, 334, 326, 327, 328, 329, 0, 0, 0, 469, 469, 469, 0, 469, 412, 412, 412, 469, 469, 412, 412, 412, 469, 412, 469, 469, 469, 469, 469, 469, 469, 412, 469, 412, 412, 469, 469, 469, 469, 469, 469, 469, 412, 412, 0, 412, 412, 412, 412, 412, 0, 469, 334, 0, 469, 469, 469, 469, 469, 469, 469, 469, 0, 469, 469, 469, 469, 0, 0, 469, 469, 469, 412, 412, 412, 412, 412, 412, 412, 412, 412, 412, 412, 412, 412, 412, 0, 0, 412, 412, 412, 469, 412, 412, 469, 469, 469, 469, 469, 412, 469, 412, 469, 412, 469, 412, 412, 412, 412, 412, 412, 412, 469, 412, 469, 469, 469, 469, 469, 469, 469, 0, 0, 0, 95, 0, 0, 0, 0, 0, 0, 0, 470, 470, 470, 0, 470, 415, 415, 415, 470, 470, 415, 415, 415, 470, 415, 470, 470, 470, 470, 470, 470, 470, 415, 470, 415, 415, 470, 470, 470, 470, 470, 470, 470, 415, 415, 0, 415, 415, 415, 415, 415, 95, 470, 0, 0, 470, 470, 470, 470, 470, 470, 470, 470, 0, 470, 470, 470, 470, 0, 0, 470, 470, 470, 415, 415, 415, 415, 415, 415, 415, 415, 415, 415, 415, 415, 415, 415, 0, 0, 415, 415, 415, 470, 415, 415, 470, 470, 470, 470, 470, 415, 470, 415, 470, 415, 470, 415, 415, 415, 415, 415, 415, 415, 470, 415, 470, 470, 470, 470, 470, 470, 470, 472, 0, 0, 0, 0, 0, 0, 0, 0, 0, 472, 0, 0, 0, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 0, 320, 321, 0, 0, 322, 323, 0, 0, 0, 0, 0, 0, 0, 0, 0, 472, 678, 324, 472, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 0, 0, 472, 472, 0, 84, 0, 472, 0, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 0, 320, 321, 0, 0, 322, 323, 0, 0, 0, 0, 0, 0, 0, 0, 472, 0, 472, 324, 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 0, 0, 0, 508, 509, 473, 0, 510, 0, 0, 0, 0, 0, 0, 160, 473, 161, 162, 472, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 0, 0, 0, 170, 171, 172, 173, 0, 0, 0, 0, 0, 0, 0, 0, 309, 473, 175, 176, 473, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 322, 323, 473, 473, 0, 86, 95, 473, 0, 95, 95, 95, 0, 324, 0, 325, 0, 326, 327, 328, 329, 0, 96, 0, 0, 309, 0, 0, 0, 0, 314, 315, 0, 412, 0, 473, 0, 473, 0, 0, 412, 322, 323, 0, 0, 95, 0, 0, 0, 0, 95, 95, 95, 95, 324, 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 0, 0, 473, 0, 96, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 472, 472, 472, 0, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 0, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 334, 472, 472, 472, 472, 472, 0, 472, 0, 0, 472, 472, 472, 472, 472, 472, 472, 472, 0, 472, 472, 472, 472, 0, 0, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 0, 0, 472, 472, 472, 472, 0, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 472, 473, 473, 473, 0, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 0, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 0, 473, 473, 473, 473, 473, 0, 473, 0, 0, 473, 473, 473, 473, 473, 473, 473, 473, 0, 473, 473, 473, 473, 0, 0, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 0, 0, 473, 473, 473, 473, 0, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 476, 0, 0, 96, 0, 0, 96, 96, 96, 0, 476, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 415, 0, 0, 0, 0, 0, 0, 415, 0, 0, 0, 476, 96, 0, 476, 0, 0, 96, 96, 96, 96, 0, 0, 0, 0, 0, 0, 0, 476, 476, 0, 85, 0, 476, 0, 0, 0, 0, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 0, 320, 321, 0, 0, 322, 323, 0, 0, 0, 0, 0, 476, 0, 476, 0, 0, 0, 324, 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 513, 514, 274, 0, 515, 0, 0, 0, 0, 0, 0, 160, 274, 161, 162, 476, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 0, 0, 0, 170, 171, 172, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 274, 175, 176, 274, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 274, 274, 0, 0, 0, 274, 520, 509, 0, 0, 521, 0, 0, 0, 0, 0, 0, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 274, 0, 274, 170, 171, 172, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 608, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 0, 274, 334, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 472, 472, 472, 0, 472, 476, 476, 476, 472, 472, 476, 476, 476, 472, 476, 472, 472, 472, 472, 472, 472, 472, 0, 476, 476, 476, 472, 472, 472, 472, 472, 472, 472, 476, 476, 0, 476, 476, 476, 476, 476, 0, 472, 0, 0, 472, 472, 472, 472, 472, 472, 472, 472, 0, 472, 472, 472, 472, 0, 0, 472, 472, 472, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 0, 0, 476, 476, 476, 472, 0, 476, 472, 472, 472, 472, 472, 476, 472, 476, 472, 476, 472, 476, 476, 476, 476, 476, 476, 476, 472, 476, 476, 472, 472, 472, 472, 472, 472, 471, 471, 471, 0, 471, 274, 274, 274, 471, 471, 274, 274, 274, 471, 274, 471, 471, 471, 471, 471, 471, 471, 0, 471, 274, 274, 471, 471, 471, 471, 471, 471, 471, 274, 274, 0, 274, 274, 274, 274, 274, 0, 471, 0, 0, 471, 471, 471, 471, 471, 471, 471, 471, 0, 471, 471, 471, 471, 0, 0, 471, 471, 471, 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, 274, 0, 0, 274, 274, 274, 471, 0, 274, 471, 471, 471, 471, 471, 274, 471, 274, 471, 274, 471, 274, 274, 274, 274, 274, 274, 274, 471, 274, 471, 471, 471, 471, 471, 471, 471, 477, 0, 0, 0, 0, 0, 0, 0, 0, 0, 477, 0, 0, 0, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 0, 320, 321, 0, 0, 322, 323, 0, 0, 0, 0, 0, 0, 0, 0, 0, 477, 0, 324, 477, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 547, 514, 477, 477, 548, 0, 0, 477, 0, 0, 0, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 0, 0, 0, 170, 171, 172, 173, 0, 477, 0, 477, 0, 0, 0, 0, 0, 0, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 478, 186, 0, 0, 0, 0, 0, 0, 0, 0, 478, 0, 0, 477, 0, 0, 0, 584, 509, 0, 0, 585, 0, 0, 0, 0, 0, 0, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 478, 169, 0, 478, 0, 0, 170, 171, 172, 173, 0, 0, 0, 0, 0, 0, 0, 478, 478, 0, 175, 176, 478, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 0, 0, 0, 0, 0, 0, 586, 514, 0, 0, 587, 0, 0, 0, 478, 0, 478, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 0, 0, 0, 170, 171, 172, 173, 0, 0, 0, 0, 655, 0, 0, 0, 478, 334, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 0, 0, 474, 474, 474, 0, 474, 477, 477, 477, 474, 474, 477, 477, 477, 474, 477, 474, 474, 474, 474, 474, 474, 474, 0, 477, 477, 477, 474, 474, 474, 474, 474, 474, 474, 477, 477, 0, 477, 477, 477, 477, 477, 0, 474, 0, 0, 474, 474, 474, 474, 474, 474, 474, 474, 0, 474, 474, 474, 474, 0, 0, 474, 474, 474, 477, 477, 477, 477, 477, 477, 477, 477, 477, 477, 477, 477, 477, 477, 0, 0, 477, 477, 477, 474, 0, 477, 474, 474, 474, 474, 474, 477, 474, 477, 474, 477, 474, 477, 477, 477, 477, 477, 477, 477, 474, 477, 477, 474, 474, 474, 474, 474, 474, 475, 475, 475, 0, 475, 478, 478, 478, 475, 475, 478, 478, 478, 475, 478, 475, 475, 475, 475, 475, 475, 475, 0, 478, 478, 478, 475, 475, 475, 475, 475, 475, 475, 478, 478, 0, 478, 478, 478, 478, 478, 0, 475, 0, 0, 475, 475, 475, 475, 475, 475, 475, 475, 0, 475, 475, 475, 475, 0, 0, 475, 475, 475, 478, 478, 478, 478, 478, 478, 478, 478, 478, 478, 478, 478, 478, 478, 0, 0, 478, 478, 478, 475, 0, 478, 475, 475, 475, 475, 475, 478, 475, 478, 475, 478, 475, 478, 478, 478, 478, 478, 478, 478, 475, 478, 478, 475, 475, 475, 475, 475, 475, 350, 0, 0, 0, 0, 0, 0, 0, 0, 0, 350, 0, 0, 0, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 0, 320, 321, 0, 0, 322, 323, 0, 0, 0, 0, 0, 0, 0, 0, 0, 350, 0, 324, 350, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 602, 509, 350, 350, 603, 0, 0, 350, 0, 0, 0, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 0, 0, 0, 170, 171, 172, 173, 0, 350, 0, 350, 0, 0, 0, 0, 0, 0, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 492, 186, 0, 0, 0, 0, 0, 0, 0, 0, 492, 0, 0, 350, 0, 0, 0, 604, 514, 0, 0, 605, 0, 0, 0, 0, 0, 0, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 492, 169, 0, 492, 0, 0, 170, 171, 172, 173, 0, 0, 0, 0, 0, 0, 0, 492, 492, 0, 175, 176, 492, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 0, 0, 0, 0, 0, 0, 645, 509, 0, 0, 646, 0, 0, 0, 492, 0, 492, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 0, 0, 0, 170, 171, 172, 173, 0, 0, 0, 0, 0, 0, 0, 0, 492, 0, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 0, 0, 251, 251, 251, 0, 251, 350, 350, 350, 251, 251, 350, 350, 350, 251, 350, 251, 251, 251, 251, 251, 251, 251, 0, 350, 350, 350, 251, 251, 251, 251, 251, 251, 251, 350, 350, 0, 350, 350, 350, 350, 350, 0, 251, 0, 0, 251, 251, 251, 251, 251, 251, 251, 251, 0, 251, 251, 251, 251, 0, 0, 251, 251, 251, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 0, 0, 350, 350, 350, 251, 0, 350, 251, 0, 251, 251, 251, 350, 251, 350, 251, 350, 251, 350, 350, 350, 350, 350, 350, 350, 251, 350, 350, 251, 251, 251, 251, 251, 251, 251, 251, 251, 0, 251, 492, 492, 492, 251, 251, 492, 492, 492, 251, 492, 251, 251, 251, 251, 251, 251, 251, 0, 492, 492, 492, 251, 251, 251, 251, 251, 251, 251, 492, 492, 0, 492, 492, 492, 492, 492, 0, 251, 0, 0, 251, 251, 251, 251, 251, 251, 251, 251, 0, 251, 251, 251, 251, 0, 0, 251, 251, 251, 492, 492, 492, 492, 492, 492, 492, 492, 492, 492, 492, 492, 492, 492, 0, 0, 492, 492, 492, 251, 0, 492, 251, 0, 251, 251, 251, 492, 251, 492, 251, 492, 251, 492, 492, 492, 492, 492, 492, 492, 251, 492, 492, 251, 251, 251, 251, 251, 251, 278, 0, 0, 0, 0, 0, 0, 0, 0, 0, 278, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 647, 514, 0, 0, 648, 0, 0, 0, 0, 0, 0, 160, 0, 161, 162, 0, 163, 164, 165, 166, 278, 167, 168, 278, 0, 169, 0, 0, 0, 0, 170, 171, 172, 173, 0, 0, 0, 278, 278, 0, 87, 0, 278, 0, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 0, 0, 857, 509, 0, 0, 858, 0, 0, 0, 278, 0, 278, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 0, 0, 169, 0, 0, 0, 286, 170, 171, 172, 173, 0, 0, 0, 0, 0, 286, 0, 0, 278, 0, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 0, 186, 0, 0, 0, 0, 0, 0, 859, 514, 0, 0, 860, 0, 286, 0, 0, 286, 0, 160, 0, 161, 162, 0, 163, 164, 165, 166, 0, 167, 168, 286, 286, 169, 0, 0, 286, 0, 170, 171, 172, 173, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 175, 176, 0, 177, 178, 179, 180, 181, 182, 183, 184, 185, 286, 186, 286, 0, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 0, 0, 0, 0, 0, 322, 323, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 324, 286, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 0, 0, 0, 0, 0, 0, 0, 0, 473, 473, 473, 0, 473, 278, 278, 278, 473, 473, 278, 278, 278, 473, 278, 473, 473, 473, 473, 473, 473, 473, 0, 0, 278, 278, 473, 473, 473, 473, 473, 473, 473, 278, 278, 0, 278, 278, 278, 278, 278, 0, 473, 0, 0, 473, 473, 473, 473, 473, 473, 473, 473, 0, 473, 473, 473, 473, 0, 0, 473, 473, 473, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 0, 0, 278, 278, 278, 473, 0, 278, 473, 473, 473, 473, 473, 278, 473, 278, 473, 278, 473, 278, 278, 278, 278, 278, 278, 278, 473, 278, 0, 473, 473, 473, 473, 473, 473, 251, 251, 251, 0, 251, 286, 286, 286, 251, 251, 286, 286, 286, 251, 286, 251, 251, 251, 251, 251, 251, 251, 0, 0, 286, 286, 251, 251, 251, 251, 251, 251, 251, 286, 286, 0, 286, 286, 286, 286, 286, 0, 251, 0, 0, 251, 251, 251, 251, 251, 251, 251, 251, 0, 251, 251, 251, 251, 0, 0, 251, 251, 251, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 286, 0, 0, 286, 286, 286, 251, 0, 286, 251, 0, 251, 251, 251, 286, 251, 286, 251, 286, 251, 286, 286, 286, 286, 286, 286, 286, 251, 286, 472, 251, 251, 251, 251, 251, 251, 0, 0, 0, 472, 0, 0, 0, 309, 310, 311, 312, 313, 314, 315, 316, 0, 318, 319, 0, 0, 0, 0, 0, 322, 323, 0, 0, 0, 0, 0, 0, 0, 0, 0, 472, 0, 324, 76, 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, 0, 0, 0, 472, 0, 84, 0, 472, 309, 310, 311, 312, 313, 314, 315, 0, 0, 318, 319, 0, 0, 0, 0, 0, 322, 323, 0, 0, 0, 0, 0, 0, 0, 0, 0, 472, 0, 324, 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, 309, 333, 0, 0, 0, 0, 0, 0, 473, 0, 0, 0, 0, 0, 0, 0, 322, 323, 473, 0, 0, 472, 0, 0, 0, 0, 0, 0, 0, 324, 0, 325, 0, 326, 327, 328, 329, 0, 0, 332, 0, 333, 0, 0, 0, 0, 0, 0, 0, 473, 0, 0, 78, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 473, 0, 86, 0, 473, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, }; } | 1060 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1060/a404cb04ade8bbc527b55cf473199686102428e1/YyTables.java/buggy/src/org/jruby/parser/YyTables.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
3238,
760,
727,
3025,
8526,
9016,
1388,
21,
1435,
288,
1377,
327,
394,
3025,
8526,
288,
1850,
576,
5026,
16,
225,
576,
5026,
16,
225,
890,
12416,
16,
225,
576,
5540,
16,
225,
576,
5026,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
565,
3238,
760,
727,
3025,
8526,
9016,
1388,
21,
1435,
288,
1377,
327,
394,
3025,
8526,
288,
1850,
576,
5026,
16,
225,
576,
5026,
16,
225,
890,
12416,
16,
225,
576,
5540,
16,
225,
576,
5026,... |
oldname = Descriptor.toJvmName(oldname); newname = Descriptor.toJvmName(newname); constPool.renameClass(oldname, newname); | oldname = Descriptor.toJvmName(oldname); newname = Descriptor.toJvmName(newname); constPool.renameClass(oldname, newname); | public final void renameClass(String oldname, String newname) { ArrayList list; int n; if (oldname.equals(newname)) return; if (oldname.equals(thisclassname)) thisclassname = newname; oldname = Descriptor.toJvmName(oldname); newname = Descriptor.toJvmName(newname); constPool.renameClass(oldname, newname); list = methods; n = list.size(); for (int i = 0; i < n; ++i) { MethodInfo minfo = (MethodInfo)list.get(i); String desc = minfo.getDescriptor(); minfo.setDescriptor(Descriptor.rename(desc, oldname, newname)); } list = fields; n = list.size(); for (int i = 0; i < n; ++i) { FieldInfo finfo = (FieldInfo)list.get(i); String desc = finfo.getDescriptor(); finfo.setDescriptor(Descriptor.rename(desc, oldname, newname)); } } | 56357 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56357/f5d84c890b70def694dbd2904f1e6d2f7f1b70e3/ClassFile.java/buggy/src/main/javassist/bytecode/ClassFile.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
918,
6472,
797,
12,
780,
1592,
529,
16,
514,
26722,
13,
288,
3639,
2407,
666,
31,
3639,
509,
290,
31,
3639,
309,
261,
1673,
529,
18,
14963,
12,
2704,
529,
3719,
5411,
327,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
727,
918,
6472,
797,
12,
780,
1592,
529,
16,
514,
26722,
13,
288,
3639,
2407,
666,
31,
3639,
509,
290,
31,
3639,
309,
261,
1673,
529,
18,
14963,
12,
2704,
529,
3719,
5411,
327,
... |
+ "\t(default 1.3)", | + "\t(default 2.0)", | public Enumeration listOptions() { Vector newVector = new Vector(7); newVector.addElement(new Option("\tUse the baLanced version\n" + "\t(default false)", "L", 0, "-L")); newVector.addElement(new Option("\tThe number of iterations to be performed.\n" + "\t(default 1)", "I", 1, "-I <int>")); newVector.addElement(new Option("\tPromotion coefficient alpha.\n" + "\t(default 1.3)", "A", 1, "-A <double>")); newVector.addElement(new Option("\tDemotion coefficient beta.\n" + "\t(default 0.85)", "B", 1, "-B <double>")); newVector.addElement(new Option("\tPrediction threshold.\n" + "\t(default -1.0 == number of attributes)", "H", 1, "-H <double>")); newVector.addElement(new Option("\tDefault weight.\n" + "\t(default 1.0)", "W", 1, "-W <double>")); newVector.addElement(new Option("\tDefault random seed.\n" + "\t(default 1)", "S", 1, "-S <int>")); return newVector.elements(); } | 6866 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6866/5bb973bf286a69ff102d7021d450f790272ef905/Winnow.java/clean/classifiers/functions/Winnow.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
13864,
666,
1320,
1435,
288,
565,
5589,
394,
5018,
273,
394,
5589,
12,
27,
1769,
3639,
394,
5018,
18,
1289,
1046,
12,
2704,
2698,
31458,
88,
3727,
326,
9846,
48,
1359,
72,
1177,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
13864,
666,
1320,
1435,
288,
565,
5589,
394,
5018,
273,
394,
5589,
12,
27,
1769,
3639,
394,
5018,
18,
1289,
1046,
12,
2704,
2698,
31458,
88,
3727,
326,
9846,
48,
1359,
72,
1177,
6... |
byte testCode = (type == Token.SHEQ) | int testCode = (type == Token.SHEQ) | private void visitIfJumpEqOp(Node node, Node child, int trueGOTO, int falseGOTO) { if (trueGOTO == -1 || falseGOTO == -1) throw Codegen.badTree(); short stackInitial = cfw.getStackTop(); int type = node.getType(); Node rChild = child.getNext(); // Optimize if one of operands is null if (child.getType() == Token.NULL || rChild.getType() == Token.NULL) { // eq is symmetric in this case if (child.getType() == Token.NULL) { child = rChild; } generateExpression(child, node); if (type == Token.SHEQ || type == Token.SHNE) { byte testCode = (type == Token.SHEQ) ? ByteCode.IFNULL : ByteCode.IFNONNULL; cfw.add(testCode, trueGOTO); } else { if (type != Token.EQ) { // swap false/true targets for != if (type != Token.NE) throw Codegen.badTree(); int tmp = trueGOTO; trueGOTO = falseGOTO; falseGOTO = tmp; } cfw.add(ByteCode.DUP); int undefCheckLabel = cfw.acquireLabel(); cfw.add(ByteCode.IFNONNULL, undefCheckLabel); short stack = cfw.getStackTop(); cfw.add(ByteCode.POP); cfw.add(ByteCode.GOTO, trueGOTO); cfw.markLabel(undefCheckLabel, stack); Codegen.pushUndefined(cfw); cfw.add(ByteCode.IF_ACMPEQ, trueGOTO); } cfw.add(ByteCode.GOTO, falseGOTO); } else { int child_dcp_register = nodeIsDirectCallParameter(child); if (child_dcp_register != -1 && rChild.getType() == Optimizer.TO_OBJECT) { Node convertChild = rChild.getFirstChild(); if (convertChild.getType() == Token.NUMBER) { cfw.addALoad(child_dcp_register); cfw.add(ByteCode.GETSTATIC, "java/lang/Void", "TYPE", "Ljava/lang/Class;"); int notNumbersLabel = cfw.acquireLabel(); cfw.add(ByteCode.IF_ACMPNE, notNumbersLabel); cfw.addDLoad(child_dcp_register + 1); cfw.addPush(convertChild.getDouble()); cfw.add(ByteCode.DCMPL); if (type == Token.EQ) cfw.add(ByteCode.IFEQ, trueGOTO); else cfw.add(ByteCode.IFNE, trueGOTO); cfw.add(ByteCode.GOTO, falseGOTO); cfw.markLabel(notNumbersLabel); // fall thru into generic handling } } generateExpression(child, node); generateExpression(rChild, node); String name; byte testCode; switch (type) { case Token.EQ: name = "eq"; testCode = ByteCode.IFNE; break; case Token.NE: name = "eq"; testCode = ByteCode.IFEQ; break; case Token.SHEQ: name = "shallowEq"; testCode = ByteCode.IFNE; break; case Token.SHNE: name = "shallowEq"; testCode = ByteCode.IFEQ; break; default: throw Codegen.badTree(); } addScriptRuntimeInvoke(name, "(Ljava/lang/Object;" +"Ljava/lang/Object;" +")Z"); cfw.add(testCode, trueGOTO); cfw.add(ByteCode.GOTO, falseGOTO); } if (stackInitial != cfw.getStackTop()) throw Codegen.badTree(); } | 13991 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13991/d3a2da86ba78c764eb7e4799c50871b182929d40/Codegen.java/clean/js/rhino/src/org/mozilla/javascript/optimizer/Codegen.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
3757,
2047,
26743,
19508,
3817,
12,
907,
756,
16,
2029,
1151,
16,
4766,
509,
638,
43,
27019,
16,
509,
629,
43,
27019,
13,
565,
288,
3639,
309,
261,
3767,
43,
27019,
422,
300,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3757,
2047,
26743,
19508,
3817,
12,
907,
756,
16,
2029,
1151,
16,
4766,
509,
638,
43,
27019,
16,
509,
629,
43,
27019,
13,
565,
288,
3639,
309,
261,
3767,
43,
27019,
422,
300,... |
Privilege p = findPriv(privs[privAll], acl); | Privilege p = Privilege.findPriv(privs[privAll], privs[privNone], acl); | public static PrivilegeSet fromEncoding(EncodedAcl acl) throws AccessException { char[] privStates = { unspecified, // privAll unspecified, // privRead unspecified, // privReadAcl unspecified, // privReadCurrentUserPrivilegeSet unspecified, // privReadFreeBusy unspecified, // privWrite unspecified, // privWriteAcl unspecified, // privWriteProperties unspecified, // privWriteContent unspecified, // privBind unspecified, // privUnbind unspecified, // privUnlock unspecified, // privNone }; while (acl.hasMore()) { char c = acl.getChar(); if ((c == ' ') || (c == inheritedFlag)) { break; } acl.back(); Privilege p = findPriv(privs[privAll], acl); if (p == null) { throw AccessException.badACL("unknown priv"); } // Set the states based on the priv we just found. setState(privStates, p, p.getDenial()); } return new PrivilegeSet(privStates); } | 50848 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50848/1324aec393994f1f212ff989362372d7c3fae7a0/Privileges.java/buggy/calendar3/access/src/edu/rpi/cct/uwcal/access/Privileges.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
760,
2301,
8203,
908,
694,
628,
4705,
12,
10397,
13538,
7895,
13,
1216,
5016,
503,
288,
565,
1149,
8526,
6015,
7629,
273,
288,
1377,
25952,
16,
282,
368,
6015,
1595,
1377,
25952,
16... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
760,
2301,
8203,
908,
694,
628,
4705,
12,
10397,
13538,
7895,
13,
1216,
5016,
503,
288,
565,
1149,
8526,
6015,
7629,
273,
288,
1377,
25952,
16,
282,
368,
6015,
1595,
1377,
25952,
16... |
public org.quickfix.field.UnderlyingSecurityAltID get(org.quickfix.field.UnderlyingSecurityAltID value) | public quickfix.field.UnderlyingSecurityAltID get(quickfix.field.UnderlyingSecurityAltID value) | public org.quickfix.field.UnderlyingSecurityAltID get(org.quickfix.field.UnderlyingSecurityAltID value) throws FieldNotFound { getField(value); return value; } | 5926 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5926/fecc27f98261270772ff182a1d4dfd94b5daa73d/SecurityStatusRequest.java/buggy/src/java/src/quickfix/fix44/SecurityStatusRequest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
9549,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
336,
12,
19525,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
225,
460,
13,
565,
1216,
2286,
2768,
225,
288,
5031,
12,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
9549,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
336,
12,
19525,
904,
18,
1518,
18,
14655,
6291,
4368,
10655,
734,
225,
460,
13,
565,
1216,
2286,
2768,
225,
288,
5031,
12,
... |
return isolation_; | autoCommit_ = false; if (getTransactionIsolationStmt == null || !(getTransactionIsolationStmt.openOnClient_ && getTransactionIsolationStmt.openOnServer_)) { getTransactionIsolationStmt = createStatementX(java.sql.ResultSet.TYPE_FORWARD_ONLY, java.sql.ResultSet.CONCUR_READ_ONLY, holdability()); } rs = getTransactionIsolationStmt.executeQuery("values current isolation"); rs.next(); String isolationStr = rs.getString(1); isolation_ = translateIsolation(isolationStr); rs.close(); | public int getTransactionIsolation() throws SQLException { try { checkForClosedConnection(); if (agent_.loggingEnabled()) { agent_.logWriter_.traceExit(this, "getTransactionIsolation", isolation_); } return isolation_; } catch ( SqlException se ) { throw se.getSQLException(); } } | 56322 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56322/ac53be6ad60875d25cc36eba0cb1220a7fbb8b3a/Connection.java/buggy/java/client/org/apache/derby/client/am/Connection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
509,
15674,
22982,
1435,
1216,
6483,
288,
3639,
775,
3639,
288,
5411,
13855,
7395,
1952,
5621,
5411,
309,
261,
5629,
27799,
11167,
1526,
10756,
288,
7734,
4040,
27799,
1330,
2289,
27799... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
509,
15674,
22982,
1435,
1216,
6483,
288,
3639,
775,
3639,
288,
5411,
13855,
7395,
1952,
5621,
5411,
309,
261,
5629,
27799,
11167,
1526,
10756,
288,
7734,
4040,
27799,
1330,
2289,
27799... |
if(path != null) return project.findMember(path.removeFirstSegments(1)); | if(path != null){ IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); return root.findMember(path); } | public static IResource findResourceForBuildResource(IBuildResource bRc){ IProject project = bRc.getBuildDescription().getConfiguration().getOwner().getProject(); IPath path = bRc.getFullPath(); if(path != null) return project.findMember(path.removeFirstSegments(1)); return null; } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/d6c3820f2ac080073cc3abf91f36b90dd97ee187/BuildDescriptionManager.java/buggy/build/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/managedbuilder/buildmodel/BuildDescriptionManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
760,
467,
1420,
1104,
1420,
1290,
3116,
1420,
12,
45,
3116,
1420,
324,
24599,
15329,
202,
202,
45,
4109,
1984,
273,
324,
24599,
18,
588,
3116,
3291,
7675,
588,
1750,
7675,
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,
482,
760,
467,
1420,
1104,
1420,
1290,
3116,
1420,
12,
45,
3116,
1420,
324,
24599,
15329,
202,
202,
45,
4109,
1984,
273,
324,
24599,
18,
588,
3116,
3291,
7675,
588,
1750,
7675,
588,
... |
unmapElement(element); return; } | unmapElement(element); return; } | protected void doUpdateItem(final Item item, Object element) { if (!(item instanceof TreeItem)) return; TreeItem treeItem = (TreeItem)item; if (treeItem.isDisposed()) { unmapElement(element); return; } colorAndFontCollector.setFontsAndColors(element); IBaseLabelProvider prov = getLabelProvider(); ITableLabelProvider tprov = null; if (prov instanceof ITableLabelProvider) { tprov = (ITableLabelProvider) prov; } int columnCount = tree.getColumnCount(); if(columnCount == 0){//If no columns were created use the label provider ViewerLabel updateLabel = new ViewerLabel(treeItem .getText(), treeItem.getImage()); buildLabel(updateLabel,element); //As it is possible for user code to run the event //loop check here. if (treeItem.isDisposed()) { unmapElement(element); return; } if(updateLabel.hasNewText()) treeItem.setText(updateLabel.getText()); if(updateLabel.hasNewImage()) treeItem.setImage(updateLabel.getImage()); } else{//Use the table based support for (int column = 0; column < columnCount; column++) { // Similar code in TableViewer.doUpdateItem() String text = "";//$NON-NLS-1$ Image image = null; treeColorAndFont.setFontsAndColors(treeItem, element,column); if (tprov == null) { if (column == 0) { ViewerLabel updateLabel = new ViewerLabel(treeItem .getText(), treeItem.getImage()); buildLabel(updateLabel,element); //As it is possible for user code to run the event //loop check here. if (treeItem.isDisposed()) { unmapElement(element); return; } text = updateLabel.getText(); image = updateLabel.getImage(); } } else { text = tprov.getColumnText(element, column); image = tprov.getColumnImage(element, column); } //Avoid setting text to null if (text == null) text = ""; //$NON-NLS-1$ treeItem.setText(column, text); if (treeItem.getImage(column) != image) { treeItem.setImage(column, image); } } } colorAndFontCollector.applyFontsAndColors(treeItem); } | 56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/d94e309c616b79ca7e205fa94a5f9687ffcbe4f8/TreeViewer.java/buggy/bundles/org.eclipse.jface/src/org/eclipse/jface/viewers/TreeViewer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
741,
1891,
1180,
12,
6385,
4342,
761,
16,
1033,
930,
13,
288,
1082,
309,
16051,
12,
1726,
1276,
4902,
1180,
3719,
327,
31,
3639,
4902,
1180,
2151,
1180,
273,
261,
2471,
1180,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
741,
1891,
1180,
12,
6385,
4342,
761,
16,
1033,
930,
13,
288,
1082,
309,
16051,
12,
1726,
1276,
4902,
1180,
3719,
327,
31,
3639,
4902,
1180,
2151,
1180,
273,
261,
2471,
1180,
... |
pixelType[0] = FormatReader.INT32; | pixelType[0] = FormatReader.UINT32; | private void initMetadata() throws FormatException, IOException { MetadataStore store = getMetadataStore(currentId); store.setImage((String) metadata.get("DataName"), null, null, null); switch (bpp % 3) { case 0: case 1: pixelType[0] = FormatReader.INT8; break; case 2: pixelType[0] = FormatReader.INT16; break; case 4: pixelType[0] = FormatReader.INT32; break; default: throw new RuntimeException( "Unknown matching for pixel byte width of: " + bpp); } store.setPixels( new Integer(getSizeX(currentId)), new Integer(getSizeY(currentId)), new Integer(getSizeZ(currentId)), new Integer(getSizeC(currentId)), new Integer(getSizeT(currentId)), new Integer(pixelType[0]), new Boolean(false), getDimensionOrder(currentId), null); Float pixX = new Float(metadata.get( "[Reference Image Parameter] - WidthConvertValue").toString()); Float pixY = new Float(metadata.get( "[Reference Image Parameter] - HeightConvertValue").toString()); store.setDimensions(pixX, pixY, null, null, null, null); } | 11426 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/11426/db080dd0a46728b8a134dea3f2915320b0ce0482/OIBReader.java/buggy/loci/formats/in/OIBReader.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
918,
1208,
2277,
1435,
1216,
4077,
503,
16,
1860,
288,
565,
6912,
2257,
1707,
273,
11159,
2257,
12,
2972,
548,
1769,
565,
1707,
18,
542,
2040,
12443,
780,
13,
1982,
18,
588,
2932,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
918,
1208,
2277,
1435,
1216,
4077,
503,
16,
1860,
288,
565,
6912,
2257,
1707,
273,
11159,
2257,
12,
2972,
548,
1769,
565,
1707,
18,
542,
2040,
12443,
780,
13,
1982,
18,
588,
2932,
... |
alloc_scope.heapFrame = alloc_scope.add_decl (Symbol.make ("heapFrame"), Compilation.objArrayType); | { alloc_scope.heapFrame = alloc_scope.add_decl (Symbol.make ("heapFrame"), Compilation.objArrayType); alloc_scope.heapFrame.setArtificial (true); } | public void assign_space () { ScopeExp alloc_scope = this; while (! (alloc_scope instanceof LambdaExp)) { ScopeExp alloc_outer = alloc_scope.outer; if (alloc_outer == null) break; alloc_scope = alloc_outer; } for (Variable var = firstVar (); var != null; var = var.nextVar ()) { Declaration decl = (Declaration) var; if (decl.offset < 0) { if (! decl.isSimple ()) { /* A variable captured by an inner Lambda is allocated in the heap frame. */ if (alloc_scope.heapFrame == null) alloc_scope.heapFrame = alloc_scope.add_decl (Symbol.make ("heapFrame"), Compilation.objArrayType); decl.baseVariable = alloc_scope.heapFrame; decl.offset = alloc_scope.frameSize++; } } } } | 40769 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/40769/bbb4cee92538f4212714dd1526b149346a5e5b56/ScopeExp.java/clean/kawa/lang/ScopeExp.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
2683,
67,
2981,
1832,
225,
288,
565,
5468,
2966,
4767,
67,
4887,
273,
333,
31,
565,
1323,
16051,
261,
9853,
67,
4887,
1276,
12801,
2966,
3719,
1377,
288,
202,
3876,
2966,
4767,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2683,
67,
2981,
1832,
225,
288,
565,
5468,
2966,
4767,
67,
4887,
273,
333,
31,
565,
1323,
16051,
261,
9853,
67,
4887,
1276,
12801,
2966,
3719,
1377,
288,
202,
3876,
2966,
4767,... |
synchronized(persistenceSync) { try { File compressedTemp = new File(persistentDownloadsTempFile+".gz"); File compressedFinal = new File(persistentDownloadsFile.toString()+".gz"); FileOutputStream fos = new FileOutputStream(compressedTemp); BufferedOutputStream bos = new BufferedOutputStream(fos); GZIPOutputStream gos = new GZIPOutputStream(bos); OutputStreamWriter osw = new OutputStreamWriter(gos); BufferedWriter w = new BufferedWriter(osw); w.write(Integer.toString(persistentRequests.length)+"\n"); for(int i=0;i<persistentRequests.length;i++) persistentRequests[i].write(w); w.close(); if(!compressedTemp.renameTo(compressedFinal)) { Logger.minor(this, "Rename failed"); compressedFinal.delete(); | Bucket[] toFree = null; try { synchronized(persistenceSync) { toFree = node.persistentTempBucketFactory.grabBucketsToFree(); try { File compressedTemp = new File(persistentDownloadsTempFile+".gz"); File compressedFinal = new File(persistentDownloadsFile.toString()+".gz"); FileOutputStream fos = new FileOutputStream(compressedTemp); BufferedOutputStream bos = new BufferedOutputStream(fos); GZIPOutputStream gos = new GZIPOutputStream(bos); OutputStreamWriter osw = new OutputStreamWriter(gos); BufferedWriter w = new BufferedWriter(osw); w.write(Integer.toString(persistentRequests.length)+"\n"); for(int i=0;i<persistentRequests.length;i++) persistentRequests[i].write(w); w.close(); | public void storePersistentRequests() { Logger.minor(this, "Storing persistent requests"); ClientRequest[] persistentRequests = getPersistentRequests(); Logger.minor(this, "Persistent requests count: "+persistentRequests.length); synchronized(persistenceSync) { try { File compressedTemp = new File(persistentDownloadsTempFile+".gz"); File compressedFinal = new File(persistentDownloadsFile.toString()+".gz"); FileOutputStream fos = new FileOutputStream(compressedTemp); BufferedOutputStream bos = new BufferedOutputStream(fos); GZIPOutputStream gos = new GZIPOutputStream(bos); OutputStreamWriter osw = new OutputStreamWriter(gos); BufferedWriter w = new BufferedWriter(osw); w.write(Integer.toString(persistentRequests.length)+"\n"); for(int i=0;i<persistentRequests.length;i++) persistentRequests[i].write(w); w.close(); if(!compressedTemp.renameTo(compressedFinal)) { Logger.minor(this, "Rename failed"); compressedFinal.delete(); if(!compressedTemp.renameTo(compressedFinal)) { Logger.error(this, "Could not rename persisted requests temp file "+persistentDownloadsTempFile+".gz to "+persistentDownloadsFile); } } } catch (IOException e) { Logger.error(this, "Cannot write persistent requests to disk: "+e); } } Logger.minor(this, "Stored persistent requests"); } | 8026 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8026/a547979f963f81a958d0283dfe08cd4387e82e23/FCPServer.java/clean/src/freenet/node/fcp/FCPServer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1707,
11906,
6421,
1435,
288,
202,
202,
3328,
18,
17364,
12,
2211,
16,
315,
510,
6053,
9195,
3285,
8863,
202,
202,
1227,
691,
8526,
9195,
6421,
273,
1689,
6572,
6421,
5621,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1707,
11906,
6421,
1435,
288,
202,
202,
3328,
18,
17364,
12,
2211,
16,
315,
510,
6053,
9195,
3285,
8863,
202,
202,
1227,
691,
8526,
9195,
6421,
273,
1689,
6572,
6421,
5621,... |
ee = new ExpressionEvaluator(getDecoratedExpression(), EXPRESSION_TYPE, getParameterNames(), getParameterTypes(), THROWN_EXCEPTIONS, null); | ee = new ExpressionEvaluator(getDecoratedExpression(), EXPRESSION_TYPE, getParameterNames(), getParameterTypes(), THROWN_EXCEPTIONS, null); | public void start() { try { ee = new ExpressionEvaluator(getDecoratedExpression(), EXPRESSION_TYPE, getParameterNames(), getParameterTypes(), THROWN_EXCEPTIONS, null); start = true; } catch (Exception e) { addError("Could not start evaluator with expression [" + expression + "]", e); } } | 46523 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46523/7e755b8978a294df3e6d9708c2e25dcac0c5d6c8/JaninoEventEvaluatorBase.java/buggy/logback-core/src/main/java/ch/qos/logback/core/boolex/JaninoEventEvaluatorBase.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
787,
1435,
288,
565,
775,
288,
1377,
14657,
273,
394,
5371,
15876,
12,
588,
7859,
690,
2300,
9334,
1850,
5675,
14227,
67,
2399,
16,
5575,
1557,
9334,
18583,
9334,
1850,
7662,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
787,
1435,
288,
565,
775,
288,
1377,
14657,
273,
394,
5371,
15876,
12,
588,
7859,
690,
2300,
9334,
1850,
5675,
14227,
67,
2399,
16,
5575,
1557,
9334,
18583,
9334,
1850,
7662,
1... |
int paramSize = paramExprs.size(); Expr eachParam = null; List newParams = new ArrayList( paramSize ); for ( int i = 0 ; i < paramSize ; ++i ) { eachParam = (Expr) paramExprs.get( i ); newParams.add( eachParam.simplify() ); | newParams.add(eachParam.simplify()); | public Expr simplify() { List paramExprs = getParameters(); int paramSize = paramExprs.size(); Expr eachParam = null; List newParams = new ArrayList( paramSize ); for ( int i = 0 ; i < paramSize ; ++i ) { eachParam = (Expr) paramExprs.get( i ); newParams.add( eachParam.simplify() ); } this.parameters = newParams; return this; } | 12974 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12974/e3c53ba7f2b7ddbce78a2f9beb9abd31c56e86d9/DefaultFunctionCallExpr.java/buggy/src/java/main/org/jaxen/expr/DefaultFunctionCallExpr.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
8074,
16499,
1435,
565,
288,
3639,
987,
579,
22947,
273,
10028,
5621,
3639,
509,
225,
579,
1225,
225,
273,
579,
22947,
18,
1467,
5621,
3639,
8074,
1517,
786,
225,
273,
446,
31,
3639... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
8074,
16499,
1435,
565,
288,
3639,
987,
579,
22947,
273,
10028,
5621,
3639,
509,
225,
579,
1225,
225,
273,
579,
22947,
18,
1467,
5621,
3639,
8074,
1517,
786,
225,
273,
446,
31,
3639... |
if (pos != 979) | if (pos < 0) | public void testConvert2() { myParser.convert(new ConversionOptions(true, true, false)); int pos = new String(myParser.content).indexOf("org.aspectj.lang.JoinPoint thisJoinPoint;"); if (pos != 937) fail("tjp has not been added."); pos = new String(myParser.content).indexOf("org.aspectj.lang.JoinPoint.StaticPart thisJoinPointStaticPart;"); if (pos != 979) fail("tjpsp has not been added."); if (myParser.content.length != 1086) fail("tjp and tjpsp have not been added correctly."); } | 13558 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13558/69cce6d59678fb8be01425dea582f88a3b6c48ab/AspectsConvertingParserTest.java/buggy/org.eclipse.ajdt.ui.tests/src/org/eclipse/ajdt/javamodel/AspectsConvertingParserTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1842,
2723,
22,
1435,
288,
3196,
202,
4811,
2678,
18,
6283,
12,
2704,
16401,
1320,
12,
3767,
16,
638,
16,
629,
10019,
3196,
202,
474,
949,
273,
394,
514,
12,
4811,
2678,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2723,
22,
1435,
288,
3196,
202,
4811,
2678,
18,
6283,
12,
2704,
16401,
1320,
12,
3767,
16,
638,
16,
629,
10019,
3196,
202,
474,
949,
273,
394,
514,
12,
4811,
2678,
... |
static void getRoots() { synchronized (mutex) {//blocking time// time measurement by rup//int ts=Timer.us(); int i, j; // add static refs to root list int addr = Native.rdMem(addrStaticRefs); int cnt = Native.rdMem(addrStaticRefs+1); for (i=0; i<cnt; ++i) { push(Native.rdMem(addr+i)); } // add complete stack of the current thread to the root list// roots = GCStkWalk.swk(RtThreadImpl.getActive(),true,false); i = Native.getSP(); for (j = 128; j <= i; ++j) { // disable the if when not using gc stack info// if (roots[j - 128] == 1) { push(Native.rdIntMem(j));// } } // Stacks from the other threads cnt = RtThreadImpl.getCnt(); for (i = 0; i < cnt; ++i) { if (i != RtThreadImpl.getActive()) { // can we allocate objects here??? // better don't do it.... // System.out.print("thread stack "); // System.out.println(i); int[] mem = RtThreadImpl.getStack(i); int sp = RtThreadImpl.getSP(i) - 128; // sp starts at 128// roots = GCStkWalk.swk(i, false, false); // System.out.print("sp="); // System.out.println(sp); for (j = 0; j <= sp; ++j) { // disable the if when not using gc stack info// if (roots[j] == 1) { push(mem[j]);// } } } }// time measurement by rup// ts = Timer.us() - ts;// System.out.print("blocking time for root scan: ");// System.out.print(ts);// System.out.println(" us"); // TODO: and what happens when the stack gets changed during // GC? } } | 45850 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45850/d1fa3e9968154a50f17be730c01e23c7f575fe77/GC.java/clean/java/target/src/common/com/jopdesign/sys/GC.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
3845,
918,
7656,
87,
1435,
288,
202,
202,
22043,
261,
29946,
13,
288,
759,
18926,
813,
759,
813,
12464,
635,
19708,
759,
474,
3742,
33,
6777,
18,
407,
5621,
1082,
202,
474,
277,
16... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
3845,
918,
7656,
87,
1435,
288,
202,
202,
22043,
261,
29946,
13,
288,
759,
18926,
813,
759,
813,
12464,
635,
19708,
759,
474,
3742,
33,
6777,
18,
407,
5621,
1082,
202,
474,
277,
16... | ||
String name = event.getTask().getTaskName(); | String name = event.getTask().getName(); | public void messageLogged( BuildEvent event ) { // Filter out messages based on priority if( event.getPriority() <= msgOutputLevel ) { StringBuffer message = new StringBuffer(); // Print out the name of the task if we're in one if( event.getTask() != null ) { String name = event.getTask().getTaskName(); if( !emacsMode ) { String label = "[" + name + "] "; for( int i = 0; i < ( LEFT_COLUMN_SIZE - label.length() ); i++ ) { message.append( " " ); } message.append( label ); } } message.append( event.getMessage() ); String msg = message.toString(); if( event.getPriority() != Project.MSG_ERR ) { out.println( msg ); } else { err.println( msg ); } log( msg ); } } | 639 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/639/1dc954f3a51bf0c5adff222d717d04c08f4bed4e/DefaultLogger.java/buggy/proposal/myrmidon/src/todo/org/apache/tools/ant/DefaultLogger.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
883,
19862,
12,
3998,
1133,
871,
262,
565,
288,
3639,
368,
4008,
596,
2743,
2511,
603,
4394,
3639,
309,
12,
871,
18,
588,
8183,
1435,
1648,
1234,
1447,
2355,
262,
3639,
288,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
883,
19862,
12,
3998,
1133,
871,
262,
565,
288,
3639,
368,
4008,
596,
2743,
2511,
603,
4394,
3639,
309,
12,
871,
18,
588,
8183,
1435,
1648,
1234,
1447,
2355,
262,
3639,
288,
... |
break _loop1268; | break _loop1269; | public final void fetchstate(AST _t) throws RecognitionException { AST fetchstate_AST_in = (_t == ASTNULL) ? null : (AST)_t; AST __t1264 = _t; AST tmp1718_AST_in = (AST)_t; match(_t,FETCH); _t = _t.getFirstChild(); AST tmp1719_AST_in = (AST)_t; match(_t,ID); _t = _t.getNextSibling(); AST tmp1720_AST_in = (AST)_t; match(_t,INTO); _t = _t.getNextSibling(); fld(_t,CQ.UPDATING); _t = _retTree; { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case INDICATOR: case Field_ref: { fetch_indicator(_t); _t = _retTree; break; } case EOF: case PERIOD: case COMMA: { break; } default: { throw new NoViableAltException(_t); } } } { _loop1268: do { if (_t==null) _t=ASTNULL; if ((_t.getType()==COMMA)) { AST tmp1721_AST_in = (AST)_t; match(_t,COMMA); _t = _t.getNextSibling(); fld(_t,CQ.UPDATING); _t = _retTree; { if (_t==null) _t=ASTNULL; switch ( _t.getType()) { case INDICATOR: case Field_ref: { fetch_indicator(_t); _t = _retTree; break; } case EOF: case PERIOD: case COMMA: { break; } default: { throw new NoViableAltException(_t); } } } } else { break _loop1268; } } while (true); } state_end(_t); _t = _retTree; _t = __t1264; _t = _t.getNextSibling(); _retTree = _t; } | 13952 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13952/865876f0e6319c071fef156818ff116c276cfdff/TreeParser01.java/buggy/trunk/org.prorefactor.core/src/org/prorefactor/treeparser01/TreeParser01.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
2158,
2019,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
2158,
2019,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
13,
692,
446,
294,
261,
9053... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
2158,
2019,
12,
9053,
389,
88,
13,
1216,
9539,
288,
9506,
202,
9053,
2158,
2019,
67,
9053,
67,
267,
273,
261,
67,
88,
422,
9183,
8560,
13,
692,
446,
294,
261,
9053... |
public void visit(JavaClass obj) { publicClass = obj.isPublic(); super.visit(obj); | public void visit(JavaClass obj) { publicClass = obj.isPublic(); super.visit(obj); | public void visit(JavaClass obj) { publicClass = obj.isPublic(); super.visit(obj); } | 7352 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7352/4748a5a9b76f3dd763ee6bc7755c932a711bd6a6/FindReturnRef.java/buggy/findbugs/src/java/edu/umd/cs/findbugs/detect/FindReturnRef.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
3757,
12,
5852,
797,
1081,
13,
377,
288,
3639,
1071,
797,
273,
1081,
18,
291,
4782,
5621,
202,
9565,
18,
11658,
12,
2603,
1769,
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,
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,
282,
1071,
918,
3757,
12,
5852,
797,
1081,
13,
377,
288,
3639,
1071,
797,
273,
1081,
18,
291,
4782,
5621,
202,
9565,
18,
11658,
12,
2603,
1769,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100... |
final URL url, final SubmitMethod method, final List parameters, final Map requestHeaders ) { lastMethod_ = method; lastParameters_ = parameters; ResponseEntry entry = (ResponseEntry)responseMap_.get(url.toExternalForm()); if( entry == null ) { entry = defaultResponseEntry_; if( entry == null ) { throw new IllegalStateException( "No response specified that can handle url ["+url.toExternalForm()+"]"); } } final ResponseEntry responseEntry = entry; return new WebResponse() { public int getStatusCode() { return responseEntry.statusCode_; } public String getStatusMessage() { return responseEntry.statusMessage_; } public String getContentType() { return responseEntry.contentType_; } public String getContentAsString() { return responseEntry.content_; } public URL getUrl() { return url; } public long getLoadTimeInMilliSeconds() { return 0; } public String getResponseHeaderValue( final String headerName ) { final Iterator iterator = responseEntry.responseHeaders_.iterator(); while( iterator.hasNext() ) { final KeyValuePair pair = (KeyValuePair)iterator.next(); if( pair.getKey().equals( headerName ) ) { return pair.getValue(); } } return null; } public InputStream getContentAsStream() throws IOException { return TextUtil.toInputStream(responseEntry.content_); } public byte[] getResponseBody() { try{ /* * this method must return raw bytes. * without encoding, getBytes use locale encoding. */ return responseEntry.content_.getBytes("ISO-8859-1"); } catch( final java.io.UnsupportedEncodingException e ){ return null; } } public String getContentCharSet() { return "ISO-8859-1"; } }; | final URL url, final SubmitMethod method, final List parameters, final Map requestParameters ) { return this.getResponse(url, FormEncodingType.URL_ENCODED, method, parameters, requestParameters); | public WebResponse getResponse( final URL url, final SubmitMethod method, final List parameters, final Map requestHeaders ) { lastMethod_ = method; lastParameters_ = parameters; ResponseEntry entry = (ResponseEntry)responseMap_.get(url.toExternalForm()); if( entry == null ) { entry = defaultResponseEntry_; if( entry == null ) { throw new IllegalStateException( "No response specified that can handle url ["+url.toExternalForm()+"]"); } } final ResponseEntry responseEntry = entry; return new WebResponse() { public int getStatusCode() { return responseEntry.statusCode_; } public String getStatusMessage() { return responseEntry.statusMessage_; } public String getContentType() { return responseEntry.contentType_; } public String getContentAsString() { return responseEntry.content_; } public URL getUrl() { return url; } public long getLoadTimeInMilliSeconds() { return 0; } public String getResponseHeaderValue( final String headerName ) { final Iterator iterator = responseEntry.responseHeaders_.iterator(); while( iterator.hasNext() ) { final KeyValuePair pair = (KeyValuePair)iterator.next(); if( pair.getKey().equals( headerName ) ) { return pair.getValue(); } } return null; } public InputStream getContentAsStream() throws IOException { return TextUtil.toInputStream(responseEntry.content_); } public byte[] getResponseBody() { try{ /* * this method must return raw bytes. * without encoding, getBytes use locale encoding. */ return responseEntry.content_.getBytes("ISO-8859-1"); } catch( final java.io.UnsupportedEncodingException e ){ return null; } } public String getContentCharSet() { return "ISO-8859-1"; } }; } | 3508 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3508/72c4847913d9683f125f1523ffc93724e7f1d30e/FakeWebConnection.java/clean/htmlunit/src/test/java/com/gargoylesoftware/htmlunit/FakeWebConnection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
2999,
1064,
6476,
12,
5411,
727,
1976,
880,
16,
5411,
727,
17320,
1305,
707,
16,
5411,
727,
987,
1472,
16,
5411,
727,
1635,
23129,
262,
288,
3639,
1142,
1305,
67,
273,
707,
31,
36... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
2999,
1064,
6476,
12,
5411,
727,
1976,
880,
16,
5411,
727,
17320,
1305,
707,
16,
5411,
727,
987,
1472,
16,
5411,
727,
1635,
23129,
262,
288,
3639,
1142,
1305,
67,
273,
707,
31,
36... |
.equals(event.getProperty())) { | .equals(propertyName)) { | public void propertyChange(PropertyChangeEvent event) { if (IPreferenceConstants .ENABLED_DECORATORS .equals(event.getProperty())) WorkbenchPlugin .getDefault() .getDecoratorManager() .restoreListeners(); if (IWorkbenchPreferenceConstants .DEFAULT_PERSPECTIVE_ID .equals(event.getProperty())) { IWorkbench workbench = WorkbenchPlugin.getDefault().getWorkbench(); AbstractUIPlugin uiPlugin = (AbstractUIPlugin) Platform.getPlugin(PlatformUI.PLUGIN_ID); String newValue = uiPlugin.getPreferenceStore().getString( IWorkbenchPreferenceConstants.DEFAULT_PERSPECTIVE_ID); workbench.getPerspectiveRegistry().setDefaultPerspective(newValue); } checkForFontUpdates(event); } | 56152 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/56152/7044c54b7a29c46b0a9da730548c78361e745127/PlatformUIPreferenceListener.java/clean/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/PlatformUIPreferenceListener.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1272,
3043,
12,
1396,
20930,
871,
13,
288,
202,
202,
430,
261,
45,
9624,
2918,
1082,
202,
18,
13560,
67,
1639,
9428,
3575,
55,
1082,
202,
18,
14963,
12,
2575,
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,
482,
918,
1272,
3043,
12,
1396,
20930,
871,
13,
288,
202,
202,
430,
261,
45,
9624,
2918,
1082,
202,
18,
13560,
67,
1639,
9428,
3575,
55,
1082,
202,
18,
14963,
12,
2575,
18,
588,
... |
Messages.getString( "org.eclipse.birt.report.designer.ui.preference.commenttemplates.defaultcomment" ) ); | Messages.getString( "org.eclipse.birt.report.designer.ui.preference.commenttemplates.defaultcomment" ) ); | public void setDefaultCommentPreference( ) { getPreferenceStore( ).setDefault( COMMENT_PREFERENCE, Messages.getString( "org.eclipse.birt.report.designer.ui.preference.commenttemplates.defaultcomment" ) ); } | 15160 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/15160/02592d02aa1066d3fcb7d374c14b7434ae94a419/ReportPlugin.java/buggy/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/ReportPlugin.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
9277,
4469,
9624,
12,
262,
202,
95,
202,
202,
588,
9624,
2257,
12,
262,
18,
542,
1868,
12,
19400,
67,
3670,
10830,
16,
9506,
202,
5058,
18,
588,
780,
12,
315,
3341,
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,
9277,
4469,
9624,
12,
262,
202,
95,
202,
202,
588,
9624,
2257,
12,
262,
18,
542,
1868,
12,
19400,
67,
3670,
10830,
16,
9506,
202,
5058,
18,
588,
780,
12,
315,
3341,
18,... |
while ((line = in.readLine()) != null) { | TokenFilter.LineTokenizer lineTokenizer = new TokenFilter.LineTokenizer(); lineTokenizer.setIncludeDelims(true); line = lineTokenizer.getToken(in); while ((line) != null) { | private void translate() throws BuildException { for (int i = 0; i < filesets.size(); i++) { FileSet fs = (FileSet) filesets.elementAt(i); DirectoryScanner ds = fs.getDirectoryScanner(getProject()); String[] srcFiles = ds.getIncludedFiles(); for (int j = 0; j < srcFiles.length; j++) { try { File dest = fileUtils.resolveFile(toDir, srcFiles[j]); //Make sure parent dirs exist, else, create them. try { File destDir = new File(dest.getParent()); if (!destDir.exists()) { destDir.mkdirs(); } } catch (Exception e) { log("Exception occured while trying to check/create " + " parent directory. " + e.getMessage(), Project.MSG_DEBUG); } destLastModified = dest.lastModified(); File src = fileUtils.resolveFile(ds.getBasedir(), srcFiles[j]); srcLastModified = src.lastModified(); //Check to see if dest file has to be recreated if (forceOverwrite || destLastModified < srcLastModified || destLastModified < bundleLastModified[0] || destLastModified < bundleLastModified[1] || destLastModified < bundleLastModified[2] || destLastModified < bundleLastModified[3] || destLastModified < bundleLastModified[4] || destLastModified < bundleLastModified[5] || destLastModified < bundleLastModified[6]) { log("Processing " + srcFiles[j], Project.MSG_DEBUG); FileOutputStream fos = new FileOutputStream(dest); BufferedWriter out = new BufferedWriter(new OutputStreamWriter(fos, destEncoding)); FileInputStream fis = new FileInputStream(src); BufferedReader in = new BufferedReader(new InputStreamReader(fis, srcEncoding)); String line; while ((line = in.readLine()) != null) { // 2003-02-21 new replace algorithm by tbee (tbee@tbee.org) // because it wasn't able to replace something like "@aaa;@bbb;" // is there a startToken // and there is still stuff following the startToken int startIndex = line.indexOf(startToken); while (startIndex >= 0 && (startIndex + startToken.length()) <= line.length()) { // the new value, this needs to be here // because it is required to calculate the next position to search from // at the end of the loop String replace = null; // we found a starttoken, is there an endtoken following? // start at token+tokenlength because start and end // token may be indentical int endIndex = line.indexOf(endToken, startIndex + startToken.length()); if (endIndex < 0) { startIndex += 1; } else { // grab the token String token = line.substring(startIndex + startToken.length(), endIndex); // If there is a white space or = or :, then // it isn't to be treated as a valid key. boolean validToken = true; for (int k = 0; k < token.length() && validToken; k++) { char c = token.charAt(k); if (c == ':' || c == '=' || Character.isSpaceChar(c)) { validToken = false; } } if (!validToken) { startIndex += 1; } else { // find the replace string if (resourceMap.containsKey(token)) { replace = (String) resourceMap.get(token); } else { replace = token; } // generate the new line line = line.substring(0, startIndex) + replace + line.substring(endIndex + endToken.length()); // set start position for next search startIndex += replace.length(); } } // find next starttoken startIndex = line.indexOf(startToken, startIndex); } out.write(line); out.newLine(); } if (in != null) { in.close(); } if (out != null) { out.close(); } } else { log("Skipping " + srcFiles[j] + " as destination file is up to date", Project.MSG_VERBOSE); } } catch (IOException ioe) { throw new BuildException(ioe.getMessage(), getLocation()); } } } } | 639 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/639/ff164b0006a8d9f5511dfc39be765d561121eea7/Translate.java/buggy/src/main/org/apache/tools/ant/taskdefs/optional/i18n/Translate.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
4204,
1435,
1216,
18463,
288,
3639,
364,
261,
474,
277,
273,
374,
31,
277,
411,
1390,
2413,
18,
1467,
5621,
277,
27245,
288,
5411,
1387,
694,
2662,
273,
261,
812,
694,
13,
13... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
4204,
1435,
1216,
18463,
288,
3639,
364,
261,
474,
277,
273,
374,
31,
277,
411,
1390,
2413,
18,
1467,
5621,
277,
27245,
288,
5411,
1387,
694,
2662,
273,
261,
812,
694,
13,
13... |
msg = pg_stream.ReceiveString(4096); | msg = pg_stream.ReceiveString(receive_sbuf, 4096, getEncoding()); | public java.sql.ResultSet ExecSQL(String sql) throws SQLException { // added Oct 7 1998 to give us thread safety. synchronized(pg_stream) { Field[] fields = null; Vector tuples = new Vector(); byte[] buf = null; int fqp = 0; boolean hfr = false; String recv_status = null, msg; int update_count = 1; int insert_oid = 0; SQLException final_error = null; // Commented out as the backend can now handle queries // larger than 8K. Peter June 6 2000 //if (sql.length() > 8192) //throw new PSQLException("postgresql.con.toolong",sql); if (getEncoding() == null) buf = sql.getBytes(); else { try { buf = sql.getBytes(getEncoding()); } catch (UnsupportedEncodingException unse) { throw new PSQLException("postgresql.con.encoding", unse); } } try { pg_stream.SendChar('Q'); buf = sql.getBytes(); pg_stream.Send(buf); pg_stream.SendChar(0); pg_stream.flush(); } catch (IOException e) { throw new PSQLException("postgresql.con.ioerror",e); } while (!hfr || fqp > 0) { Object tup=null; // holds rows as they are recieved int c = pg_stream.ReceiveChar(); switch (c) { case 'A': // Asynchronous Notify pid = pg_stream.ReceiveInteger(4); msg = pg_stream.ReceiveString(8192); break; case 'B': // Binary Data Transfer if (fields == null) throw new PSQLException("postgresql.con.tuple"); tup = pg_stream.ReceiveTuple(fields.length, true); // This implements Statement.setMaxRows() if(maxrows==0 || tuples.size()<maxrows) tuples.addElement(tup); break; case 'C': // Command Status recv_status = pg_stream.ReceiveString(8192); // Now handle the update count correctly. if(recv_status.startsWith("INSERT") || recv_status.startsWith("UPDATE") || recv_status.startsWith("DELETE")) { try { update_count = Integer.parseInt(recv_status.substring(1+recv_status.lastIndexOf(' '))); } catch(NumberFormatException nfe) { throw new PSQLException("postgresql.con.fathom",recv_status); } if(recv_status.startsWith("INSERT")) { try { insert_oid = Integer.parseInt(recv_status.substring(1+recv_status.indexOf(' '),recv_status.lastIndexOf(' '))); } catch(NumberFormatException nfe) { throw new PSQLException("postgresql.con.fathom",recv_status); } } } if (fields != null) hfr = true; else { try { pg_stream.SendChar('Q'); pg_stream.SendChar(' '); pg_stream.SendChar(0); pg_stream.flush(); } catch (IOException e) { throw new PSQLException("postgresql.con.ioerror",e); } fqp++; } break; case 'D': // Text Data Transfer if (fields == null) throw new PSQLException("postgresql.con.tuple"); tup = pg_stream.ReceiveTuple(fields.length, false); // This implements Statement.setMaxRows() if(maxrows==0 || tuples.size()<maxrows) tuples.addElement(tup); break; case 'E': // Error Message msg = pg_stream.ReceiveString(4096); final_error = new SQLException(msg); hfr = true; break; case 'I': // Empty Query int t = pg_stream.ReceiveChar(); if (t != 0) throw new PSQLException("postgresql.con.garbled"); if (fqp > 0) fqp--; if (fqp == 0) hfr = true; break; case 'N': // Error Notification addWarning(pg_stream.ReceiveString(4096)); break; case 'P': // Portal Name String pname = pg_stream.ReceiveString(8192); break; case 'T': // MetaData Field Description if (fields != null) throw new PSQLException("postgresql.con.multres"); fields = ReceiveFields(); break; case 'Z': // backend ready for query, ignore for now :-) break; default: throw new PSQLException("postgresql.con.type",new Character((char)c)); } } if (final_error != null) throw final_error; return getResultSet(this, fields, tuples, recv_status, update_count, insert_oid); } } | 46409 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46409/5383b5d8ed6da5c90bcbdb63401b7d1d75db563d/Connection.java/clean/src/interfaces/jdbc/org/postgresql/Connection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
2252,
18,
4669,
18,
13198,
3889,
3997,
12,
780,
1847,
13,
1216,
6483,
565,
288,
202,
759,
3096,
29482,
2371,
23673,
28,
358,
8492,
584,
2650,
24179,
18,
202,
22043,
12,
8365,
67,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
2252,
18,
4669,
18,
13198,
3889,
3997,
12,
780,
1847,
13,
1216,
6483,
565,
288,
202,
759,
3096,
29482,
2371,
23673,
28,
358,
8492,
584,
2650,
24179,
18,
202,
22043,
12,
8365,
67,
... |
run(TaskListView.getDefault().getSelectedTask()); | run(TaskListView.getFromActivePerspective().getSelectedTask()); | public void run() {// MylarPlugin.getContextManager().actionObserved(this, Boolean.TRUE.toString()); run(TaskListView.getDefault().getSelectedTask()); } | 51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/c8574cd79281b6b10b04091344dadfb5ebf98c51/TaskActivateAction.java/clean/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasklist/ui/actions/TaskActivateAction.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1086,
1435,
288,
759,
202,
202,
12062,
7901,
3773,
18,
29120,
1318,
7675,
1128,
9013,
2155,
12,
2211,
16,
3411,
18,
18724,
18,
10492,
10663,
202,
202,
2681,
12,
2174,
682,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
1086,
1435,
288,
759,
202,
202,
12062,
7901,
3773,
18,
29120,
1318,
7675,
1128,
9013,
2155,
12,
2211,
16,
3411,
18,
18724,
18,
10492,
10663,
202,
202,
2681,
12,
2174,
682,
... |
if (DEBUG) System.out.println(" getState > early"); | void scheduleEarly (OPT_Instruction inst) { if (getState(inst) >= early) { // System.out.println(" getState > early"); return; } setState(inst, early); // already on outer level? if (ir.HIRInfo.LoopStructureTree.getLoopNestDepth(getBlock(inst)) == 0) { // System.out.println(" already on outer level"); return; } // explicitely INCLUDE instructions if (!shouldMove(inst, ir)) { // System.out.println(" shouldMove failed"); return; } OPT_Instruction earlyPos = ir.firstInstructionInCodeOrder(); // dependencies via scalar operands earlyPos = scheduleDefEarly(inst.getUses(), earlyPos); // memory dependencies if (inst.isImplicitLoad() || inst.isImplicitStore() || inst.isPEI()) earlyPos = scheduleDefEarly(ssad.getHeapUses(inst), earlyPos, inst); // System.out.println(" moved to " + earlyPos); // move inst to its new location move(inst, upto(earlyPos, inst)); } | 5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/899bab79edb764416fef61626a089b4e8909d32f/OPT_LICM.java/buggy/rvm/src/vm/compilers/optimizing/optimizations/global/ssa/codePlacement/OPT_LICM.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
309,
261,
9394,
13,
2332,
18,
659,
18,
8222,
2932,
21821,
8997,
405,
11646,
8863,
309,
261,
9394,
13,
2332,
18,
659,
18,
8222,
2932,
21821,
8997,
405,
11646,
8863,
918,
430,
261,
9394,
13,
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,
309,
261,
9394,
13,
2332,
18,
659,
18,
8222,
2932,
21821,
8997,
405,
11646,
8863,
309,
261,
9394,
13,
2332,
18,
659,
18,
8222,
2932,
21821,
8997,
405,
11646,
8863,
918,
430,
261,
9394,
13,
2... | |
if (edge == null) return false; if(_edges.contains(edge)) return false; Object end0 = null, end1 = null; if (edge instanceof MAssociationRole) { List conns = ((MAssociationRole)edge).getConnections(); if (conns.size() < 2) return false; MAssociationEndRole ae0 = (MAssociationEndRole) conns.get(0); MAssociationEndRole ae1 = (MAssociationEndRole) conns.get(1); if (ae0 == null || ae1 == null) return false; end0 = ae0.getType(); end1 = ae1.getType(); | if (edge == null) return false; if (_edges.contains(edge)) return false; Object end0 = null, end1 = null; if (edge instanceof MAssociationRole) { List conns = ((MAssociationRole) edge).getConnections(); if (conns.size() < 2) return false; MAssociationEndRole ae0 = (MAssociationEndRole) conns.get(0); MAssociationEndRole ae1 = (MAssociationEndRole) conns.get(1); if (ae0 == null || ae1 == null) return false; end0 = ae0.getType(); end1 = ae1.getType(); } if (edge instanceof MGeneralization) { MGeneralization gen = (MGeneralization) edge; end0 = gen.getParent(); end1 = gen.getChild(); } if (edge instanceof MDependency) { Collection clients = ((MDependency) edge).getClients(); Collection suppliers = ((MDependency) edge).getSuppliers(); if (clients == null || suppliers == null) return false; end0 = ((Object[]) clients.toArray())[0]; end1 = ((Object[]) suppliers.toArray())[0]; } if (end0 == null || end1 == null) return false; if (!_nodes.contains(end0)) return false; if (!_nodes.contains(end1)) return false; return true; | public boolean canAddEdge(Object edge) { if (edge == null) return false; if(_edges.contains(edge)) return false; Object end0 = null, end1 = null; if (edge instanceof MAssociationRole) { List conns = ((MAssociationRole)edge).getConnections(); if (conns.size() < 2) return false; MAssociationEndRole ae0 = (MAssociationEndRole) conns.get(0); MAssociationEndRole ae1 = (MAssociationEndRole) conns.get(1); if (ae0 == null || ae1 == null) return false; end0 = ae0.getType(); end1 = ae1.getType(); } if (edge instanceof MGeneralization) { MGeneralization gen = (MGeneralization)edge; end0 = gen.getParent(); end1 = gen.getChild(); } if (edge instanceof MDependency) { Collection clients = ((MDependency)edge).getClients(); Collection suppliers = ((MDependency)edge).getSuppliers(); if (clients == null || suppliers == null) return false; end0 = ((Object[])clients.toArray())[0]; end1 = ((Object[])suppliers.toArray())[0]; } if (end0 == null || end1 == null) return false; if (!_nodes.contains(end0)) return false; if (!_nodes.contains(end1)) return false; return true; } | 7166 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/7166/ca3bcb5d6dd283c4553bcbfe50b108dc5d499768/CollabDiagramGraphModel.java/clean/src_new/org/argouml/uml/diagram/collaboration/CollabDiagramGraphModel.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1250,
848,
986,
6098,
12,
921,
3591,
13,
225,
288,
565,
309,
261,
7126,
422,
446,
13,
327,
629,
31,
565,
309,
24899,
8746,
18,
12298,
12,
7126,
3719,
327,
629,
31,
565,
1033,
67... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
1250,
848,
986,
6098,
12,
921,
3591,
13,
225,
288,
565,
309,
261,
7126,
422,
446,
13,
327,
629,
31,
565,
309,
24899,
8746,
18,
12298,
12,
7126,
3719,
327,
629,
31,
565,
1033,
67... |
public Object[] getElements(Object input) { | public Object[] getElements(final Object input) { | public Object[] getElements(Object input) { final Long documentId = (Long) input; Collection<DocumentVersion> versionList; try { versionList = documentModel.listVersions( documentId, versionIdDescending); } catch(final ParityException px) { logger.error("Could not obtain the document version list.", px); versionList = new Vector<DocumentVersion>(0); } return versionList.toArray(new DocumentVersion[] {}); } | 53635 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/53635/1079dba1f2428715d6e9cbb4b718da0416175e43/ProviderFactory.java/clean/client-ui/src/main/java/com/thinkparity/browser/application/browser/display/provider/ProviderFactory.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1875,
202,
482,
1033,
8526,
8886,
12,
921,
810,
13,
288,
9506,
202,
6385,
3407,
28573,
273,
261,
3708,
13,
810,
31,
9506,
202,
2532,
32,
2519,
1444,
34,
1177,
682,
31,
9506,
202,
698,
288,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1875,
202,
482,
1033,
8526,
8886,
12,
921,
810,
13,
288,
9506,
202,
6385,
3407,
28573,
273,
261,
3708,
13,
810,
31,
9506,
202,
2532,
32,
2519,
1444,
34,
1177,
682,
31,
9506,
202,
698,
288,
... |
getLogger().debug("Java2DRenderer stopped"); | log.debug("Java2DRenderer stopped"); | public void stopRenderer() throws IOException { getLogger().debug("Java2DRenderer stopped"); renderingDone = true; numberOfPages = currentPageNumber; // TODO set all vars to null for gc if (numberOfPages == 0) { new FOPException("No page could be rendered"); } } | 5268 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5268/990f5e0aee12f2b62f6a961dec312bb3eb5f3e56/Java2DRenderer.java/clean/src/java/org/apache/fop/render/java2d/Java2DRenderer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
2132,
6747,
1435,
1216,
1860,
288,
3639,
613,
18,
4148,
2932,
5852,
22,
40,
6747,
9627,
8863,
3639,
9782,
7387,
273,
638,
31,
3639,
7922,
5716,
273,
15117,
1854,
31,
3639,
368,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
2132,
6747,
1435,
1216,
1860,
288,
3639,
613,
18,
4148,
2932,
5852,
22,
40,
6747,
9627,
8863,
3639,
9782,
7387,
273,
638,
31,
3639,
7922,
5716,
273,
15117,
1854,
31,
3639,
368,... |
((Element)node).setAttribute("xml:base", baseURI); | ((Element)node).setAttribute ("xml:base", baseURI); | protected final void handleBaseURI (Node node){ if (fDocumentImpl != null) { // REVISIT: remove dependency on our implementation when // DOM L3 becomes REC String baseURI = null; short nodeType = node.getNodeType(); if (nodeType == Node.ELEMENT_NODE) { // if an element already has xml:base attribute // do nothing if (fNamespaceAware) { if (((Element)node).getAttributeNodeNS("http://www.w3.org/XML/1998/namespace","base")!=null) { return; } } else if (((Element)node).getAttributeNode("xml:base") != null) { return; } // retrive the baseURI from the entity reference baseURI = ((EntityReferenceImpl)fCurrentNode).getBaseURI(); if (baseURI !=null && !baseURI.equals(fDocumentImpl.getDocumentURI())) { if (fNamespaceAware) { ((Element)node).setAttributeNS("http://www.w3.org/XML/1998/namespace","base", baseURI); } else { ((Element)node).setAttribute("xml:base", baseURI); } } } else if (nodeType == Node.PROCESSING_INSTRUCTION_NODE) { baseURI = ((EntityReferenceImpl)fCurrentNode).getBaseURI(); if (baseURI !=null && fErrorHandler != null) { DOMErrorImpl error = new DOMErrorImpl(); error.fType = "infoset-baseURI"; error.fRelatedData = baseURI; error.fSeverity = DOMError.SEVERITY_WARNING; fErrorHandler.getErrorHandler().handleError(error); } } } } | 4434 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4434/9d1dbf89c75cf6f564facc2b605dd9f2cf2dac4d/AbstractDOMParser.java/clean/src/org/apache/xerces/parsers/AbstractDOMParser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
727,
918,
1640,
2171,
3098,
261,
907,
756,
15329,
3639,
309,
261,
74,
2519,
2828,
480,
446,
13,
288,
5411,
368,
2438,
26780,
1285,
30,
1206,
4904,
603,
3134,
4471,
1347,
5411,
368,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
727,
918,
1640,
2171,
3098,
261,
907,
756,
15329,
3639,
309,
261,
74,
2519,
2828,
480,
446,
13,
288,
5411,
368,
2438,
26780,
1285,
30,
1206,
4904,
603,
3134,
4471,
1347,
5411,
368,
... |
if (ex) { if (getRuby().getActMethodScope() == Constants.SCOPE_PRIVATE) { noex = Constants.NOEX_PRIVATE; } else if (getRuby().getActMethodScope() == Constants.SCOPE_PROTECTED) { noex = Constants.NOEX_PROTECTED; } else { noex = Constants.NOEX_PUBLIC; } } | if (ex) { if (getRuby().getActMethodScope() == Constants.SCOPE_PRIVATE) { noex = Constants.NOEX_PRIVATE; } else if (getRuby().getActMethodScope() == Constants.SCOPE_PROTECTED) { noex = Constants.NOEX_PROTECTED; } else { noex = Constants.NOEX_PUBLIC; } } | public void addAttribute(RubyId id, boolean read, boolean write, boolean ex) { // RubyInterpreter intrprtr = getRuby().getInterpreter(); int noex = Constants.NOEX_PUBLIC; if (ex) { if (getRuby().getActMethodScope() == Constants.SCOPE_PRIVATE) { noex = Constants.NOEX_PRIVATE; } else if (getRuby().getActMethodScope() == Constants.SCOPE_PROTECTED) { noex = Constants.NOEX_PROTECTED; } else { noex = Constants.NOEX_PUBLIC; } } String name = id.toName(); RubyId attrIV = getRuby().intern("@" + name); if (read) { addMethod(id, new NodeFactory(getRuby()).newIVar(attrIV), noex); // id.clearCache(); funcall(getRuby().intern("method_added"), id.toSymbol()); } if (write) { id = getRuby().intern(name + "="); addMethod(id, new NodeFactory(getRuby()).newAttrSet(attrIV), noex); // id.clearCache(); funcall(getRuby().intern("method_added"), id.toSymbol()); } } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/0a7181933af700ea8025a4197f3a5ebcc08333c3/RubyModule.java/buggy/org/jruby/RubyModule.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
10759,
12,
54,
10340,
548,
612,
16,
1250,
855,
16,
1250,
1045,
16,
1250,
431,
13,
288,
202,
202,
759,
19817,
30010,
28600,
683,
313,
273,
4170,
10340,
7675,
588,
30010,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
10759,
12,
54,
10340,
548,
612,
16,
1250,
855,
16,
1250,
1045,
16,
1250,
431,
13,
288,
202,
202,
759,
19817,
30010,
28600,
683,
313,
273,
4170,
10340,
7675,
588,
30010,
5... |
seller.say("Sell what? Don't cheat me or I might 'ave to hurt you!"); | seller.say("Whut? Is not unnerstand... Maybe I hit you until you make sense!"); | protected void createDialog() { // TODO: The code is identical to Sato's SheepBuyerBehaviour, // except that the phrasing is different. Unite them. class SheepBuyerBehaviour extends BuyerBehaviour { SheepBuyerBehaviour(Map<String, Integer> items) { super(items); } @Override public int getCharge(Player player) { if (player.hasSheep()) { Sheep sheep = (Sheep) StendhalRPWorld.get().get(player.getSheep()); return Math.round(getUnitPrice(chosenItem) * ((float) sheep.getWeight() / (float) sheep.MAX_WEIGHT)); } else { return 0; } } @Override public boolean transactAgreedDeal(SpeakerNPC seller, Player player) { // amount is currently ignored. if (player.hasSheep()) { Sheep sheep = (Sheep) StendhalRPWorld.get().get(player.getSheep()); if (seller.squaredDistance(sheep) > 5 * 5) { seller.say("*drool* Sheep flesh! Bring da sheep here!"); } else { say("*LOVELY*. Take dis money!"); payPlayer(player); StendhalRPRuleProcessor.get().removeNPC(sheep); StendhalRPWorld.get().remove(sheep.getID()); player.removeSheep(sheep); player.notifyWorldAboutChanges(); return true; } } else { seller.say("Sell what? Don't cheat me or I might 'ave to hurt you!"); } return false; } } Map<String, Integer> buyitems = new HashMap<String, Integer>(); buyitems.put("sheep", 1500); addGreeting(); addJob(getName() + " du buy cheepz frrom humanz."); addHelp(getName() + " buy sheep! Sell me sheep! " + getName() + " is hungry!"); addBuyer(new SheepBuyerBehaviour(buyitems)); addGoodbye(); } | 4438 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4438/8b95f6a366e456dc1f53a8cc9b3bcce9c96d844d/OrcishHappyMeal.java/buggy/src/games/stendhal/server/maps/quests/OrcishHappyMeal.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1875,
202,
1117,
918,
752,
6353,
1435,
288,
9506,
202,
759,
2660,
30,
1021,
981,
353,
12529,
358,
25793,
83,
1807,
348,
580,
881,
38,
16213,
19376,
477,
16,
9506,
202,
759,
1335,
716,
326,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1875,
202,
1117,
918,
752,
6353,
1435,
288,
9506,
202,
759,
2660,
30,
1021,
981,
353,
12529,
358,
25793,
83,
1807,
348,
580,
881,
38,
16213,
19376,
477,
16,
9506,
202,
759,
1335,
716,
326,
1... |
mainSymbol = getLaunch().getLaunchConfiguration().getAttribute( ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN_SYMBOL, ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_SYMBOL_DEFAULT ); | ILaunchConfiguration launchConfig = getLaunch().getLaunchConfiguration(); if (launchConfig.getAttribute( ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN, false)) { String mainSymbol = new String( ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_SYMBOL_DEFAULT ); mainSymbol = getLaunch().getLaunchConfiguration().getAttribute( ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN_SYMBOL, ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_SYMBOL_DEFAULT ); ICDILocation location = getCDITarget().createFunctionLocation( "", mainSymbol ); setInternalTemporaryBreakpoint( location ); } | public void restart() throws DebugException { if ( !canRestart() ) { return; } String mainSymbol = new String( ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_SYMBOL_DEFAULT ); try { mainSymbol = getLaunch().getLaunchConfiguration().getAttribute( ICDTLaunchConfigurationConstants.ATTR_DEBUGGER_STOP_AT_MAIN_SYMBOL, ICDTLaunchConfigurationConstants.DEBUGGER_STOP_AT_MAIN_SYMBOL_DEFAULT ); } catch( CoreException e ) { requestFailed( e.getMessage(), e ); } ICDILocation location = getCDITarget().createFunctionLocation( "", mainSymbol ); //$NON-NLS-1$ setInternalTemporaryBreakpoint( location ); final CDebugElementState newState = CDebugElementState.RESTARTING; changeState( newState ); try { getCDITarget().restart(); } catch( CDIException e ) { if ( getState() == newState ) { restoreOldState(); } targetRequestFailed( e.getMessage(), e ); } } | 6192 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6192/66948345f02c12d4e7920c3ced4e223e86d4d30d/CDebugTarget.java/clean/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CDebugTarget.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
7870,
1435,
1216,
4015,
503,
288,
202,
202,
430,
261,
401,
4169,
15057,
1435,
262,
288,
1082,
202,
2463,
31,
202,
202,
97,
202,
202,
780,
2774,
5335,
273,
394,
514,
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,
225,
202,
482,
918,
7870,
1435,
1216,
4015,
503,
288,
202,
202,
430,
261,
401,
4169,
15057,
1435,
262,
288,
1082,
202,
2463,
31,
202,
202,
97,
202,
202,
780,
2774,
5335,
273,
394,
514,
12,
... |
showStackFrame(lastFrame); | showStopLine(lastFrame); | public void enterInterrupt(Main.StackFrame lastFrame, String threadTitle, String alertMessage) { statusBar.setText("Thread: " + threadTitle); showStackFrame(lastFrame); if (alertMessage != null) { MessageDialogWrapper.showMessageDialog(this, alertMessage, "Exception in Script", JOptionPane.ERROR_MESSAGE); } JMenu menu = getJMenuBar().getMenu(0); //menu.getItem(0).setEnabled(false); // File->Load menu = getJMenuBar().getMenu(2); menu.getItem(0).setEnabled(false); // Debug->Break int count = menu.getItemCount(); for (int i = 1; i < count; ++i) { menu.getItem(i).setEnabled(true); } boolean b = false; for (int ci = 0, cc = toolBar.getComponentCount(); ci < cc; ci++) { toolBar.getComponent(ci).setEnabled(b); b = true; } toolBar.setEnabled(true); // raise the debugger window toFront(); Main.ContextData contextData = lastFrame.contextData(); context.enable(); JComboBox ctx = context.context; Vector toolTips = context.toolTips; context.disableUpdate(); int frameCount = contextData.frameCount(); ctx.removeAllItems(); // workaround for JDK 1.4 bug that caches selected value even after // removeAllItems() is called ctx.setSelectedItem(null); toolTips.removeAllElements(); for (int i = 0; i < frameCount; i++) { Main.StackFrame frame = contextData.getFrame(i); String url = frame.getUrl(); int lineNumber = frame.getLineNumber(); String shortName = url; if (url.length() > 20) { shortName = "..." + url.substring(url.length() - 17); } String location = "\"" + shortName + "\", line " + lineNumber; ctx.insertItemAt(location, i); location = "\"" + url + "\", line " + lineNumber; toolTips.addElement(location); } context.enableUpdate(); ctx.setSelectedIndex(0); ctx.setMinimumSize(new Dimension(50, ctx.getMinimumSize().height)); } | 47609 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47609/1e8e9be6240bd419cb4ce7800a26a09d70dd4e27/DebugGui.java/buggy/js/rhino/toolsrc/org/mozilla/javascript/tools/debugger/DebugGui.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
6103,
14126,
12,
6376,
18,
2624,
3219,
1142,
3219,
16,
514,
2650,
4247,
16,
1171,
9079,
514,
6881,
1079,
13,
565,
288,
3639,
1267,
5190,
18,
542,
1528,
2932,
3830,
30,
315,
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,
918,
6103,
14126,
12,
6376,
18,
2624,
3219,
1142,
3219,
16,
514,
2650,
4247,
16,
1171,
9079,
514,
6881,
1079,
13,
565,
288,
3639,
1267,
5190,
18,
542,
1528,
2932,
3830,
30,
315,
3... |
if (toprocess.fossilize && toprocess.fossilizedbinding == null) { | if (toprocess.fossilize && toprocess.fossilizedbinding == null && renderfossilized) { | public void processComponent(UIComponent toprocesso) { if (toprocesso instanceof UIBound) { UIBound toprocess = (UIBound) toprocesso; // If there is a value in the SVE, return it to the control. SubmittedValueEntry sve = rsvc.byID(toprocess.getFullID()); if (sve != null) { toprocess.updateValue(sve.newvalue); } else if (toprocess.valuebinding != null && (toprocess.acquireValue() == null || UITypes .isPlaceholder(toprocess.acquireValue()))) { // a bound component ALWAYS contains a value of the correct type. Object oldvalue = toprocess.acquireValue(); String stripbinding = toprocess.valuebinding.value; BeanResolver resolver = computeResolver(toprocess); Object flatvalue = null; try { flatvalue = alterer.getFlattenedValue(stripbinding, beanlocator, oldvalue.getClass(), resolver); } catch (Exception e) { // don't let a bad bean model prevent the correct reference being // encoded Logger.log.info("Error resolving EL reference " + stripbinding, e); } if (flatvalue != null) { toprocess.updateValue(flatvalue); } } if (toprocess.submittingname == null) { toprocess.submittingname = toprocess.getFullID(); } if (toprocess.valuebinding != null) { // TODO: Think carefully whether we want these "encoded" bindings to // EVER appear in the component tree. Tradeoffs - we would need to // create // more classes that renderer could recognise to compute bindings, and // increase its knowledge about the rest of RSF. if (toprocess.fossilize && toprocess.fossilizedbinding == null) { UIParameter fossilized = fossilizedconverter .computeFossilizedBinding(toprocess); toprocess.fossilizedbinding = fossilized; } if (toprocess.darreshaper != null) { toprocess.fossilizedshaper = fossilizedconverter .computeReshaperBinding(toprocess); } } } } | 49142 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49142/61b4681a8808a99144361fa7517e33c49cb0cfb7/ValueFixer.java/clean/src/uk/org/ponder/rsf/componentprocessor/ValueFixer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
1071,
918,
1207,
1841,
12,
5370,
1841,
358,
2567,
83,
13,
288,
565,
309,
261,
3669,
16127,
83,
1276,
6484,
3499,
13,
288,
1377,
6484,
3499,
358,
2567,
273,
261,
5370,
3499,
13,
358,
256... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1207,
1841,
12,
5370,
1841,
358,
2567,
83,
13,
288,
565,
309,
261,
3669,
16127,
83,
1276,
6484,
3499,
13,
288,
1377,
6484,
3499,
358,
2567,
273,
261,
5370,
3499,
13,
358,
256... |
value = child3.getAttributeNS("http: Assertion.assert(value!=null && value.equals("http: | value = child3.getAttributeNS("http: Assertion.assert(value!=null && value.equals("http: | public static void main( String[] argv) { try { boolean namespaces = true; System.out.println("Running dom.dom3.Test..."); System.setProperty(DOMImplementationRegistry.PROPERTY,"org.apache.xerces.dom.DOMImplementationSourceImpl"); DOMImplementationLS impl = (DOMImplementationLS)DOMImplementationRegistry.newInstance().getDOMImplementation("LS-Load"); Assertion.assert(impl!=null, "domImplementation != null"); DOMBuilder builder = impl.createDOMBuilder(DOMImplementationLS.MODE_SYNCHRONOUS, null); DOMWriter writer = impl.createDOMWriter(); DOMConfiguration config = writer.getConfig(); config.setParameter("namespaces",(namespaces)?Boolean.TRUE:Boolean.FALSE); config.setParameter("validate",Boolean.FALSE); //---------------------------- // TEST: lookupNamespacePrefix // isDefaultNamespace // lookupNamespaceURI //---------------------------- //System.out.println("TEST #1: lookupNamespacePrefix, isDefaultNamespace, lookupNamespaceURI, input: tests/dom/dom3/input.xml"); { Document doc = builder.parseURI("tests/dom/dom3/input.xml"); NodeList ls = doc.getElementsByTagName("a:elem_a"); NodeImpl elem = (NodeImpl)ls.item(0); if (namespaces) { //System.out.println("[a:elem_a].lookupNamespacePrefix('http://www.example.com', true) == null"); Assertion.assert(elem.lookupNamespacePrefix( "http://www.example.com", true) == null, "[a:elem_a].lookupNamespacePrefix(http://www.example.com)==null"); //System.out.println("[a:elem_a].isDefaultNamespace('http://www.example.com') == true"); Assertion.assert(elem.isDefaultNamespace("http://www.example.com") == true, "[a:elem_a].isDefaultNamespace(http://www.example.com)==true"); //System.out.println("[a:elem_a].lookupNamespacePrefix('http://www.example.com', false) == ns1"); Assertion.assert(elem.lookupNamespacePrefix( "http://www.example.com", false).equals("ns1"), "[a:elem_a].lookupNamespacePrefix(http://www.example.com)==ns1"); Assertion.assert(elem.lookupNamespaceURI("xsi").equals("http://www.w3.org/2001/XMLSchema-instance"), "[a:elem_a].lookupNamespaceURI('xsi') == 'http://www.w3.org/2001/XMLSchema-instance'" ); } else { Assertion.assert( elem.lookupNamespacePrefix( "http://www.example.com", false) == null,"lookupNamespacePrefix(http://www.example.com)==null"); } ls = doc.getElementsByTagName("bar:leaf"); elem = (NodeImpl)ls.item(0); Assertion.assert(elem.lookupNamespacePrefix("url1:",false).equals("foo"), "[bar:leaf].lookupNamespacePrefix('url1:', false) == foo"); //System.out.println("[bar:leaf].lookupNamespacePrefix('url1:', false) == "+ ); //System.out.println("==>Create b:baz with namespace 'b:' and xmlns:x='b:'"); ls = doc.getElementsByTagName("baz"); elem = (NodeImpl)ls.item(0); ls = doc.getElementsByTagName("elem8"); elem = (NodeImpl)ls.item(0); Element e1 = doc.createElementNS("b:","p:baz"); e1.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:x", "b:"); elem.appendChild(e1); Assertion.assert(((NodeImpl)e1).lookupNamespacePrefix("b:",false).equals("p"), "[p:baz].lookupNamespacePrefix('b:', false) == p"); //System.out.println("[p:baz].lookupNamespacePrefix('b:', false) == "+ ((NodeImpl)e1).lookupNamespacePrefix("b:",false)); Assertion.assert(elem.lookupNamespaceURI("xsi").equals("http://www.w3.org/2001/XMLSchema-instance"), "[bar:leaf].lookupNamespaceURI('xsi') == 'http://www.w3.org/2001/XMLSchema-instance'" ); } //************************ //* Test normalizeDocument() //************************ //System.out.println("TEST #2: normalizeDocumention() - 3 errors, input: tests/dom/dom3/schema.xml"); { errorCounter = 0; config = builder.getConfig(); config.setParameter("error-handler",errorHandler); config.setParameter("validate", Boolean.TRUE); DocumentImpl core = (DocumentImpl)builder.parseURI("tests/dom/dom3/schema.xml"); Assertion.assert(errorCounter == 0, "No errors should be reported"); errorCounter = 0; NodeList ls2 = core.getElementsByTagName("decVal"); Element testElem = (Element)ls2.item(0); testElem.removeAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns"); ls2 = core.getElementsByTagName("v02:decVal"); testElem = (Element)ls2.item(0); testElem.setPrefix("myPrefix"); Element root = core.getDocumentElement(); Element newElem = core.createElementNS(null, "decVal"); String data="4.5"; if (true) { data = "string"; } newElem.appendChild(core.createTextNode(data)); root.insertBefore(newElem, testElem); newElem = core.createElementNS(null, "notInSchema"); newElem.appendChild(core.createTextNode("added new element")); root.insertBefore(newElem, testElem); root.appendChild(core.createElementNS("UndefinedNamespace", "NS1:foo")); config = core.getConfig(); config.setParameter("error-handler",errorHandler); config.setParameter("validate", Boolean.TRUE); core.normalizeDocument(); Assertion.assert(errorCounter == 3, "3 errors should be reported"); errorCounter = 0; config.setParameter("validate", Boolean.FALSE); config.setParameter("comments", Boolean.FALSE); core.normalizeDocument(); Assertion.assert(errorCounter == 0, "No errors should be reported"); config = builder.getConfig(); config.setParameter("validate", Boolean.FALSE); } //************************ //* Test normalizeDocument() //************************ // System.out.println("TEST #3: normalizeDocumention() + psvi, input: data/personal-schema.xml"); { errorCounter = 0; config = builder.getConfig(); config.setParameter("error-handler",errorHandler); config.setParameter("validate", Boolean.TRUE); config.setParameter("psvi", Boolean.TRUE); DocumentImpl core = (DocumentImpl)builder.parseURI("data/personal-schema.xml"); Assertion.assert(errorCounter == 0, "No errors should be reported"); NodeList ls2 = core.getElementsByTagName("person"); Element testElem = (Element)ls2.item(0); Assertion.assert(((ElementPSVI)testElem).getElementDeclaration().getName().equals("person"), "testElem decl"); Element e1 = core.createElementNS(null, "person"); core.getDocumentElement().appendChild(e1); e1.setAttributeNS(null, "id", "newEmp"); Element e2 = core.createElementNS(null, "name"); e2.appendChild(core.createElementNS(null, "family")); e2.appendChild(core.createElementNS(null, "given")); e1.appendChild(e2); e1.appendChild(core.createElementNS(null, "email")); Element e3 = core.createElementNS(null, "link"); e3.setAttributeNS(null, "manager", "Big.Boss"); e1.appendChild(e3); testElem.removeAttributeNode(testElem.getAttributeNodeNS(null, "contr")); NamedNodeMap map = testElem.getAttributes(); config = core.getConfig(); errorCounter = 0; config.setParameter("psvi", Boolean.TRUE); config.setParameter("error-handler",errorHandler); config.setParameter("validate", Boolean.TRUE); core.normalizeDocument(); Assertion.assert(errorCounter == 0, "No errors should be reported"); Assertion.assert(((ElementPSVI)e1).getElementDeclaration().getName().equals("person"), "e1 decl"); config = builder.getConfig(); config.setParameter("validate", Boolean.FALSE); } //************************ //* Test normalizeDocument(): core tests //************************ // System.out.println("TEST #4: normalizeDocument() core"); { // check that namespace normalization algorithm works correctly Document doc= new DocumentImpl(); Element root = doc.createElementNS("http://www.w3.org/1999/XSL/Transform", "xsl:stylesheet"); doc.appendChild(root); root.setAttributeNS("http://attr1", "xsl:attr1",""); Element child1 = doc.createElementNS("http://child1", "NS2:child1"); child1.setAttributeNS("http://attr2", "NS2:attr2",""); root.appendChild(child1); Element child2 = doc.createElementNS("http://child2","NS4:child2"); child2.setAttributeNS("http://attr3","attr3", ""); root.appendChild(child2); Element child3 = doc.createElementNS("http://www.w3.org/1999/XSL/Transform","xsl:child3"); child3.setAttributeNS("http://a1","attr1", ""); child3.setAttributeNS("http://a2","xsl:attr2", ""); child3.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:a1", "http://a1"); child3.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:xsl", "http://a2"); Element child4 = doc.createElementNS(null, "child4"); child4.setAttributeNS("http://a1", "xsl:attr1", ""); child4.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns", "default"); child3.appendChild(child4); root.appendChild(child3); ((CoreDocumentImpl)doc).normalizeDocument(); // // assertions // // xsl:stylesheet should include 2 namespace declarations String name = root.getNodeName(); Assertion.assert(name.equals("xsl:stylesheet"), "xsl:stylesheet"); String value = root.getAttributeNS("http://www.w3.org/2000/xmlns/", "xsl"); Assertion.assert(value!=null, "xmlns:xsl != null"); Assertion.assert(value.equals("http://www.w3.org/1999/XSL/Transform"), "xmlns:xsl="+value); value = root.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS1"); Assertion.assert(value!=null && value.equals("http://attr1"), "xmlns:NS1="+value); // child includes 2 namespace decls Assertion.assert(child1.getNodeName().equals("NS2:child1"), "NS2:child1"); value = child1.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS2"); Assertion.assert(value!=null && value.equals("http://child1"), "xmlns:NS2="+value); value = child1.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS3"); Assertion.assert(value!=null && value.equals("http://attr2"), "xmlns:NS3="+value); // child3 Assertion.assert(child3.getNodeName().equals("xsl:child3"), "xsl:child3"); value = child3.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS6"); Assertion.assert(value!=null && value.equals("http://a2"), "xmlns:NS6="+value); value = child3.getAttributeNS("http://www.w3.org/2000/xmlns/", "a1"); Assertion.assert(value!=null && value.equals("http://a1"), "xmlns:a1="+value); value = child3.getAttributeNS("http://www.w3.org/2000/xmlns/", "xsl"); Assertion.assert(value!=null && value.equals("http://www.w3.org/1999/XSL/Transform"), "xmlns:xsl="+value); Attr attr = child3.getAttributeNodeNS("http://a2", "attr2"); Assertion.assert(attr != null, "NS6:attr2 !=null"); Assertion.assert(child3.getAttributes().getLength() == 5, "xsl:child3 has 5 attrs"); // child 4 Attr temp = child4.getAttributeNodeNS("http://www.w3.org/2000/xmlns/", "xmlns"); Assertion.assert(temp.getNodeName().equals("xmlns"), "attribute name is xmlns"); Assertion.assert(temp.getNodeValue().length() == 0, "xmlns=''"); /* OutputFormat format = new OutputFormat((Document)doc); format.setLineSeparator(LineSeparator.Windows); format.setIndenting(true); format.setLineWidth(0); format.setPreserveSpace(true); XMLSerializer serializer = new XMLSerializer(System.out, format); serializer.serialize(doc); */ } //************************ //* Test normalizeDocument(): core tests //************************ //System.out.println("TEST #4: namespace fixup during serialization"); { Document doc= new DocumentImpl(); Element root = doc.createElementNS("http://www.w3.org/1999/XSL/Transform", "xsl:stylesheet"); doc.appendChild(root); root.setAttributeNS("http://attr1", "xsl:attr1",""); Element child1 = doc.createElementNS("http://child1", "NS2:child1"); child1.setAttributeNS("http://attr2", "NS2:attr2",""); root.appendChild(child1); Element child2 = doc.createElementNS("http://child2","NS4:child2"); child2.setAttributeNS("http://attr3","attr3", ""); root.appendChild(child2); Element child3 = doc.createElementNS("http://www.w3.org/1999/XSL/Transform","xsl:child3"); child3.setAttributeNS("http://a1","attr1", ""); child3.setAttributeNS("http://a2","xsl:attr2", ""); child3.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:a1", "http://a1"); child3.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:xsl", "http://a2"); Element child4 = doc.createElementNS(null, "child4"); child4.setAttributeNS("http://a1", "xsl:attr1", ""); child4.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns", "default"); child3.appendChild(child4); root.appendChild(child3); // serialize data writer.getConfig().setParameter("namespaces", Boolean.TRUE); String xmlData = writer.writeToString(doc); Reader r = new StringReader(xmlData); DOMInputSource in = impl.createDOMInputSource(); in.setCharacterStream(r); doc = builder.parse(in); // // make sure algorithm works correctly // root = doc.getDocumentElement(); child1 = (Element)root.getFirstChild(); child2 = (Element)child1.getNextSibling(); child3 = (Element)child2.getNextSibling(); // xsl:stylesheet should include 2 namespace declarations String name = root.getNodeName(); Assertion.assert(name.equals("xsl:stylesheet"), "xsl:stylesheet"); String value = root.getAttributeNS("http://www.w3.org/2000/xmlns/", "xsl"); Assertion.assert(value!=null, "xmlns:xsl != null"); Assertion.assert(value.equals("http://www.w3.org/1999/XSL/Transform"), "xmlns:xsl="+value); value = root.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS1"); Assertion.assert(value!=null && value.equals("http://attr1"), "xmlns:NS1="+value); // child includes 2 namespace decls Assertion.assert(child1.getNodeName().equals("NS2:child1"), "NS2:child1"); value = child1.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS2"); Assertion.assert(value!=null && value.equals("http://child1"), "xmlns:NS2="+value); value = child1.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS3"); Assertion.assert(value!=null && value.equals("http://attr2"), "xmlns:NS3="+value); // child3 Assertion.assert(child3.getNodeName().equals("xsl:child3"), "xsl:child3"); value = child3.getAttributeNS("http://www.w3.org/2000/xmlns/", "NS6"); Assertion.assert(value!=null && value.equals("http://a2"), "xmlns:NS6="+value); value = child3.getAttributeNS("http://www.w3.org/2000/xmlns/", "a1"); Assertion.assert(value!=null && value.equals("http://a1"), "xmlns:a1="+value); value = child3.getAttributeNS("http://www.w3.org/2000/xmlns/", "xsl"); Assertion.assert(value!=null && value.equals("http://www.w3.org/1999/XSL/Transform"), "xmlns:xsl="+value); Attr attr = child3.getAttributeNodeNS("http://a2", "attr2"); Assertion.assert(attr != null, "NS6:attr2 !=null"); Assertion.assert(child3.getAttributes().getLength() == 5, "xsl:child3 has 5 attrs"); //OutputFormat format = new OutputFormat((Document)doc); //format.setLineSeparator(LineSeparator.Windows); //format.setIndenting(true); //format.setLineWidth(0); //format.setPreserveSpace(true); //XMLSerializer serializer = new XMLSerializer(System.out, format); //serializer.serialize(doc); } //************************ // TEST: replaceWholeText() // getWholeText() // //************************ //System.out.println("TEST #5: wholeText, input: tests/dom/dom3/wholeText.xml"); { config = builder.getConfig(); config.setParameter("error-handler",errorHandler); config.setParameter("validate", Boolean.FALSE); config.setParameter("entities", Boolean.TRUE); DocumentImpl doc = (DocumentImpl)builder.parseURI("tests/dom/dom3/wholeText.xml"); Element root = doc.getDocumentElement(); Element test = (Element)doc.getElementsByTagName("elem").item(0); test.appendChild(doc.createTextNode("Address: ")); test.appendChild(doc.createEntityReference("ent2")); test.appendChild(doc.createTextNode("City: ")); test.appendChild(doc.createEntityReference("ent1")); DocumentType doctype = doc.getDoctype(); Node entity = doctype.getEntities().getNamedItem("ent3"); NodeList ls = test.getChildNodes(); Assertion.assert(ls.getLength()==5, "List length"); String compare1 = "Home Address: 1900 Dallas Road (East) City: Dallas. California. USA PO #5668"; Assertion.assert(((TextImpl)ls.item(0)).getWholeText().equals(compare1), "Compare1"); String compare2 = "Address: 1900 Dallas Road (East) City: Dallas. California. USA PO #5668"; Assertion.assert(((TextImpl)ls.item(1)).getWholeText().equals(compare2), "Compare2"); //TEST replaceWholeText() ((NodeImpl)ls.item(0)).setReadOnly(true, true); TextImpl original = (TextImpl)ls.item(0); Node newNode = original.replaceWholeText("Replace with this text"); ls = test.getChildNodes(); Assertion.assert(ls.getLength() == 1, "Length == 1"); Assertion.assert(ls.item(0).getNodeValue().equals("Replace with this text"), "Replacement works"); Assertion.assert(newNode != original, "New node created"); // replace text for node which is not yet attached to the tree Text text = doc.createTextNode("readonly"); ((NodeImpl)text).setReadOnly(true, true); text = ((TextImpl)text).replaceWholeText("Data"); Assertion.assert(text.getNodeValue().equals("Data"), "New value 'Data'"); // test with second child that does not have any content test = (Element)doc.getElementsByTagName("elem").item(1); try { ((TextImpl)test.getFirstChild()).replaceWholeText("can't replace"); } catch (DOMException e){ Assertion.assert(e !=null); } String compare3 = "Test: The Content ends here. "; //Assertion.assert(((Text)test.getFirstChild()).getWholeText().equals(compare3), "Compare3"); } //************************ // TEST: schema-type // schema-location // //************************ { errorCounter = 0; config = builder.getConfig(); config.setParameter("error-handler",errorHandler); config.setParameter("entity-resolver",resolver); config.setParameter("validate", Boolean.TRUE); config.setParameter("psvi", Boolean.TRUE); // schema-type is not set validate against both grammars errorCounter = 0; DocumentImpl core2 = (DocumentImpl)builder.parseURI("tests/dom/dom3/both-error.xml"); Assertion.assert(errorCounter == 4, "4 errors should be reported"); errorCounter = 0; // set schema-type to be XML Schema config.setParameter("schema-type", "http://www.w3.org/2001/XMLSchema"); // test parsing a file that has both XML schema and DTD core2 = (DocumentImpl)builder.parseURI("tests/dom/dom3/both.xml"); Assertion.assert(errorCounter == 0, "No errors should be reported"); // parse a file with XML schema and DTD but validate against DTD only errorCounter = 0; config.setParameter("schema-type","http://www.w3.org/TR/REC-xml"); core2 = (DocumentImpl)builder.parseURI("tests/dom/dom3/both-error.xml"); Assertion.assert(errorCounter == 3, "3 errors should be reported"); // parse a file with DTD only but set schema-location and // validate against XML Schema // set schema location core2 = (DocumentImpl)builder.parseURI("tests/dom/dom3/both-error.xml"); // normalize document errorCounter = 0; Element root = core2.getDocumentElement(); root.removeAttributeNS("http://www.w3.org/2001/XMLSchema", "xsi"); root.removeAttributeNS("http://www.w3.org/2001/XMLSchema", "noNamespaceSchemaLocation"); config = core2.getConfig(); config.setParameter("error-handler",errorHandler); config.setParameter("schema-type", "http://www.w3.org/2001/XMLSchema"); config.setParameter("schema-location","personal.xsd"); config.setParameter("entity-resolver",resolver); config.setParameter("validate", Boolean.TRUE); core2.normalizeDocument(); Assertion.assert(errorCounter == 1, "1 error should be reported: "+errorCounter); } } catch ( Exception ex ) { ex.printStackTrace(); } } StringBuffer fError = new StringBuffer(); public boolean handleError(DOMError error){ fError.setLength(0); short severity = error.getSeverity(); if (severity == error.SEVERITY_ERROR) { errorCounter++; fError.append("[Error]"); } if (severity == error.SEVERITY_FATAL_ERROR) { fError.append("[FatalError]"); } if (severity == error.SEVERITY_WARNING) { fError.append("[Warning]"); } DOMLocator locator = error.getLocation(); if (locator != null) { // line:colon:offset fError.append(locator.getLineNumber()); fError.append(":"); fError.append(locator.getColumnNumber()); fError.append(":"); fError.append(locator.getOffset()); Node node = locator.getErrorNode(); if (node != null) { fError.append("["); fError.append(locator.getErrorNode().getNodeName()); fError.append("]"); } String systemId = locator.getUri(); if (systemId != null) { int index = systemId.lastIndexOf('/'); if (index != -1) systemId = systemId.substring(index + 1); fError.append(":"); fError.append(systemId); } fError.append(": "); fError.append(error.getMessage()); } //System.out.println(fError.toString()); return true; } /** * @see org.w3c.dom.ls.DOMEntityResolver#resolveEntity(String, String, String) */ public DOMInputSource resolveEntity(String publicId, String systemId, String baseURI) { try { DOMImplementationLS impl = (DOMImplementationLS) DOMImplementationRegistry.newInstance().getDOMImplementation( "LS-Load"); DOMInputSource source = impl.createDOMInputSource(); if (systemId.equals("personal.xsd")) { source.setSystemId("data/personal.xsd"); } else { source.setSystemId("data/personal.dtd"); } return source; } catch (Exception e) { return null; } } | 4434 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/4434/9dd190d6830014d5dbc3548c37e966a3b4ff12c2/Test.java/buggy/tests/dom/dom3/Test.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
514,
8526,
5261,
13,
288,
3639,
775,
288,
5411,
1250,
7728,
273,
638,
31,
5411,
2332,
18,
659,
18,
8222,
2932,
7051,
4092,
18,
9859,
23,
18,
4709,
7070,
1769,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
514,
8526,
5261,
13,
288,
3639,
775,
288,
5411,
1250,
7728,
273,
638,
31,
5411,
2332,
18,
659,
18,
8222,
2932,
7051,
4092,
18,
9859,
23,
18,
4709,
7070,
1769,
... |
frame.getContentPane().add(mv); | frame.getContentPane().add(datePicker); | public void run() { JFrame frame = new JFrame(); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); JXDatePicker mv = new JXDatePicker(); mv.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { System.out.println( ((JXMonthView) e.getSource()).getSelection()); } }); frame.getContentPane().add(mv); frame.pack(); frame.setVisible(true); } | 47551 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/47551/eb53082d5759a29bc9fc6cbf400dfd1bcd480d7d/JXDatePicker.java/clean/src/java/org/jdesktop/swingx/JXDatePicker.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
918,
1086,
1435,
288,
7734,
804,
3219,
2623,
273,
394,
804,
3219,
5621,
7734,
2623,
18,
542,
1868,
4605,
2988,
12,
46,
3219,
18,
28682,
67,
673,
67,
13384,
1769,
7734,
804,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
2398,
1071,
918,
1086,
1435,
288,
7734,
804,
3219,
2623,
273,
394,
804,
3219,
5621,
7734,
2623,
18,
542,
1868,
4605,
2988,
12,
46,
3219,
18,
28682,
67,
673,
67,
13384,
1769,
7734,
804,
60,
1... |
protected Control createLists(Composite control) { GridData gd; GridLayout layout; // Search expression Group group = new Group(control, SWT.NONE); layout = new GridLayout(); layout.numColumns = 6; group.setLayout(layout); gd = new GridData(GridData.FILL_HORIZONTAL); gd.horizontalSpan = 5; group.setLayoutData(gd); // Labels Label label = new Label(group, SWT.LEFT); label.setText("Status"); label = new Label(group, SWT.LEFT); label.setText("Resolution"); label = new Label(group, SWT.LEFT); label.setText("Severity"); label = new Label(group, SWT.LEFT); label.setText("Priority"); label = new Label(group, SWT.LEFT); label.setText("Hardware"); label = new Label(group, SWT.LEFT); label.setText("OS"); // Lists status = new List(group, SWT.MULTI | SWT.V_SCROLL | SWT.BORDER); gd = new GridData(GridData.FILL_HORIZONTAL); gd.heightHint = 40; status.setLayoutData(gd); resolution = new List(group, SWT.MULTI | SWT.V_SCROLL | SWT.BORDER); gd = new GridData(GridData.FILL_HORIZONTAL); gd.heightHint = 40; resolution.setLayoutData(gd); severity = new List(group, SWT.MULTI | SWT.V_SCROLL | SWT.BORDER); gd = new GridData(GridData.FILL_HORIZONTAL); gd.heightHint = 40; severity.setLayoutData(gd); priority = new List(group, SWT.MULTI | SWT.V_SCROLL | SWT.BORDER); gd = new GridData(GridData.FILL_HORIZONTAL); gd.heightHint = 40; priority.setLayoutData(gd); hardware = new List(group, SWT.MULTI | SWT.V_SCROLL | SWT.BORDER); gd = new GridData(GridData.FILL_HORIZONTAL); gd.heightHint = 40; hardware.setLayoutData(gd); os = new List(group, SWT.MULTI | SWT.V_SCROLL | SWT.BORDER); gd = new GridData(GridData.FILL_HORIZONTAL); gd.heightHint = 40; os.setLayoutData(gd); return group; } | 51989 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51989/fec7424c90714d3bb3e31f7fbe0ed914b805a795/BugzillaSearchPage.java/clean/org.eclipse.mylyn.bugzilla.ui/src/org/eclipse/mylyn/bugzilla/ui/search/BugzillaSearchPage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1117,
8888,
752,
7432,
12,
9400,
3325,
13,
288,
202,
202,
6313,
751,
15551,
31,
202,
202,
6313,
3744,
3511,
31,
9506,
202,
759,
5167,
2652,
202,
202,
1114,
1041,
273,
394,
3756,
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,
225,
202,
1117,
8888,
752,
7432,
12,
9400,
3325,
13,
288,
202,
202,
6313,
751,
15551,
31,
202,
202,
6313,
3744,
3511,
31,
9506,
202,
759,
5167,
2652,
202,
202,
1114,
1041,
273,
394,
3756,
12... | ||
for (int i = 0; i < children.length; i++) internalExpandToLevel(children[i], newLevel); | for (int i = 0; i < children.length; i++) { internalExpandToLevel(children[i], newLevel); } | protected void internalExpandToLevel(Widget widget, int level) { if (level == ALL_LEVELS || level > 0) { createChildren(widget); if (widget instanceof Item) setExpanded((Item) widget, true); if (level == ALL_LEVELS || level > 1) { Item[] children = getChildren(widget); if (children != null) { int newLevel = (level == ALL_LEVELS ? ALL_LEVELS : level - 1); for (int i = 0; i < children.length; i++) internalExpandToLevel(children[i], newLevel); } } } } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/391f2606b4ea2c1fb5052d938ca90877ee7631f6/AbstractTreeViewer.java/clean/bundles/org.eclipse.jface/src/org/eclipse/jface/viewers/AbstractTreeViewer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
918,
2713,
12271,
774,
2355,
12,
4609,
3604,
16,
509,
1801,
13,
288,
3639,
309,
261,
2815,
422,
8061,
67,
10398,
55,
747,
1801,
405,
374,
13,
288,
377,
202,
202,
2640,
4212,
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,
4750,
918,
2713,
12271,
774,
2355,
12,
4609,
3604,
16,
509,
1801,
13,
288,
3639,
309,
261,
2815,
422,
8061,
67,
10398,
55,
747,
1801,
405,
374,
13,
288,
377,
202,
202,
2640,
4212,
12,
... |
protected ObjectMetaClass(String name, Class builtinClass, RubyClass superClass) { this(name, builtinClass, superClass, superClass.getRuntime().getClass("Object").getCRef()); | public ObjectMetaClass(IRuby runtime) { super(runtime, null /*Would be Class if it existed yet */, null, null, "Object"); this.builtinClass = RubyObject.class; | protected ObjectMetaClass(String name, Class builtinClass, RubyClass superClass) { this(name, builtinClass, superClass, superClass.getRuntime().getClass("Object").getCRef()); } | 50661 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50661/5e2d21a7295d01b2d891cfc8c8e67af99a3d858e/ObjectMetaClass.java/buggy/src/org/jruby/runtime/builtin/meta/ObjectMetaClass.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
14648,
797,
12,
780,
508,
16,
1659,
15273,
797,
16,
19817,
797,
18846,
13,
288,
3639,
333,
12,
529,
16,
15273,
797,
16,
18846,
16,
18846,
18,
588,
5576,
7675,
588,
797,
2932,
921,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
14648,
797,
12,
780,
508,
16,
1659,
15273,
797,
16,
19817,
797,
18846,
13,
288,
3639,
333,
12,
529,
16,
15273,
797,
16,
18846,
16,
18846,
18,
588,
5576,
7675,
588,
797,
2932,
921,... |
new Label( displayArea, SWT.NONE ).setText( LABEL_LOCATION ); | new Label( displayArea, SWT.NONE ).setText( REQUIED_MARK + LABEL_LOCATION ); | private void switchToURI( ) { new Label( displayArea, SWT.NONE ).setText( LABEL_LOCATION ); locationEditor = new Text( displayArea, SWT.BORDER | SWT.SINGLE ); locationEditor.setLayoutData( new GridData( GridData.FILL_HORIZONTAL ) ); locationEditor.addModifyListener( new ModifyListener( ) { public void modifyText( ModifyEvent e ) { updateButtons( ); } } ); Composite buttonArea = new Composite( displayArea, SWT.NONE ); buttonArea.setLayout( UIUtil.createGridLayoutWithoutMargin( 2, true ) ); buttonArea.setLayoutData( new GridData( ) ); createBrowerButton( buttonArea, locationEditor, true, false ); createExpressionButton( buttonArea, locationEditor ); createTargetBar( ); } | 46013 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46013/456c2580ebbb17874b3c7a9a1530105e88e0b4d5/HyperlinkBuilder.java/clean/UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/ui/dialogs/HyperlinkBuilder.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1620,
774,
3098,
12,
262,
202,
95,
202,
202,
2704,
5287,
12,
2562,
5484,
16,
348,
8588,
18,
9826,
262,
18,
542,
1528,
12,
18210,
67,
15277,
11272,
202,
202,
3562,
6946,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
1620,
774,
3098,
12,
262,
202,
95,
202,
202,
2704,
5287,
12,
2562,
5484,
16,
348,
8588,
18,
9826,
262,
18,
542,
1528,
12,
18210,
67,
15277,
11272,
202,
202,
3562,
6946,
... |
if (VM.VerifyAssertions) VM.assert(VM_Processor.nativeProcessors[i] != null); | if (VM.VerifyAssertions) VM._assert(VM_Processor.nativeProcessors[i] != null); | private void initiateCollection() throws VM_PragmaUninterruptible { int maxCollectorThreads; // check that scheduler initialization is complete // if (!VM_Scheduler.allProcessorsInitialized) { VM.sysWrite(" Garbage collection required before system fully initialized\n"); VM.sysWrite(" Specify larger than default heapsize on command line\n"); VM_Scheduler.dumpStack(); VM.shutdown(-1); } if (debug_native) { // VM_Scheduler.trace("VM_Handshake:initiateCollection","dumping machine..."); // VM_Scheduler.dumpVirtualMachine(); VM_Scheduler.trace("\nVM_Handshake:initiateCollection","collectorQueue:"); VM_Scheduler.writeString("before waiting:"); VM_Scheduler.collectorQueue.dump(); } // wait for all gc threads to finish preceeding collection cycle // include NativeDaemonProcessor collector thread in the count - if it exists // check for null to allow builds without a NativeDaemon (see VM_Scheduler) if (!VM.BuildForSingleVirtualProcessor && VM_Scheduler.processors[VM_Scheduler.nativeDPndx] != null ) maxCollectorThreads = VM_Scheduler.numProcessors + 1; else maxCollectorThreads = VM_Scheduler.numProcessors; VM_Scheduler.collectorMutex.lock(); while (VM_Scheduler.collectorQueue.length() < maxCollectorThreads) { VM_Scheduler.collectorMutex.unlock(); if (trace) VM_Scheduler.trace("VM_Handshake", "mutator: waiting for previous collection to finish"); VM_Thread.getCurrentThread().yield(); VM_Scheduler.collectorMutex.lock(); } VM_Scheduler.collectorMutex.unlock(); if (debug_native) { VM_Scheduler.writeString("after waiting:"); VM_Scheduler.collectorQueue.dump(); } // Acquire global lockout field (at fixed address in the boot record). // This field will be released when gc completes while (true) { int lockoutVal = VM_Magic.prepare(VM_BootRecord.the_boot_record, VM_Entrypoints.lockoutProcessorField.offset); if ( lockoutVal == 0) { if(VM_Magic.attempt(VM_BootRecord.the_boot_record, VM_Entrypoints.lockoutProcessorField.offset, 0, LOCKOUT_GC_WORD)) break; } else { if (debug_native) VM_Scheduler.traceHex("VM_Handshake:initiateCollection", "lockoutLock contains",lockoutVal); } } // reset counter for collector threads arriving to participate in the collection VM_CollectorThread.participantCount[0] = 0; // reset rendezvous counters to 0, the decision about which collector threads // will participate has moved to the run method of CollectorThread // VM_CollectorThread.gcBarrier.resetRendezvous(); // scan all the native Virtual Processors and attempt to block those executing // native C, to prevent returning to java during collection. the first collector // thread will wait for those not blocked to reach the SIGWAIT state. // (see VM_CollectorThread.run) // for (int i = 1; i <= VM_Processor.numberNativeProcessors; i++) { if (VM.VerifyAssertions) VM.assert(VM_Processor.nativeProcessors[i] != null); VM_Processor.nativeProcessors[i].lockInCIfInC(); if (trace) { int newStatus = VM_Processor.vpStatus[VM_Processor.nativeProcessors[i].vpStatusIndex]; VM_Scheduler.trace("VM_Handshake.initiateCollection:", "Native Processor", i); VM_Scheduler.trace(" ", "new vpStatus ", newStatus); } } // Dequeue and schedule collector threads on ALL RVM Processors, // including those running system daemon threads (ex. NativeDaemonProcessor) // VM_Scheduler.collectorMutex.lock(); while (VM_Scheduler.collectorQueue.length() > 0) { VM_Thread t = VM_Scheduler.collectorQueue.dequeue(); t.scheduleHighPriority(); VM_Processor p = t.processorAffinity; // set thread switch requested condition in VP p.threadSwitchRequested = -1; } VM_Scheduler.collectorMutex.unlock(); } // initiateCollection | 5245 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5245/40e21dc6ed844793c7ae07ad49c4ba40eadcacf4/VM_Handshake.java/buggy/rvm/src/vm/memoryManagers/watson/common/synchronization/VM_Handshake.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
918,
18711,
2532,
1435,
1216,
8251,
67,
2050,
9454,
984,
31847,
1523,
288,
565,
509,
943,
7134,
13233,
31,
565,
368,
866,
716,
8129,
10313,
353,
3912,
565,
368,
202,
565,
309,
16051... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
282,
3238,
918,
18711,
2532,
1435,
1216,
8251,
67,
2050,
9454,
984,
31847,
1523,
288,
565,
509,
943,
7134,
13233,
31,
565,
368,
866,
716,
8129,
10313,
353,
3912,
565,
368,
202,
565,
309,
16051... |
protected Binding getBinding(HttpServletRequest request, HttpServletResponse response, Writer out) throws IOException { // Set up the script context Binding binding = new Binding(); GroovyObject controller = (GroovyObject)request.getAttribute(GrailsApplicationAttributes.CONTROLLER); if(controller!=null) { binding.setVariable(GroovyPage.REQUEST, controller.getProperty(ControllerDynamicMethods.REQUEST_PROPERTY)); binding.setVariable(GroovyPage.RESPONSE, controller.getProperty(ControllerDynamicMethods.RESPONSE_PROPERTY)); binding.setVariable(GroovyPage.FLASH, controller.getProperty(ControllerDynamicMethods.FLASH_SCOPE_PROPERTY)); binding.setVariable(GroovyPage.SERVLET_CONTEXT, context); ApplicationContext appContext = (ApplicationContext)context.getAttribute(GrailsApplicationAttributes.APPLICATION_CONTEXT); binding.setVariable(GroovyPage.APPLICATION_CONTEXT, appContext); binding.setVariable(GrailsApplication.APPLICATION_ID, appContext.getBean(GrailsApplication.APPLICATION_ID)); binding.setVariable(GrailsApplicationAttributes.CONTROLLER, controller); binding.setVariable(GroovyPage.SESSION, controller.getProperty(GetSessionDynamicProperty.PROPERTY_NAME)); binding.setVariable(GroovyPage.PARAMS, controller.getProperty(GetParamsDynamicProperty.PROPERTY_NAME)); binding.setVariable(GroovyPage.OUT, out); } else { // if there is no controller in the request configure using existing attributes, creating objects where necessary GrailsApplicationAttributes attrs = (GrailsApplicationAttributes)request.getAttribute(GrailsApplicationAttributes.REQUEST_SCOPE_ID); binding.setVariable(GroovyPage.REQUEST, request); binding.setVariable(GroovyPage.RESPONSE, response); binding.setVariable(GroovyPage.FLASH, attrs.getFlashScope(request)); binding.setVariable(GroovyPage.SERVLET_CONTEXT, context); ApplicationContext appContext = (ApplicationContext)context.getAttribute(GrailsApplicationAttributes.APPLICATION_CONTEXT); binding.setVariable(GroovyPage.APPLICATION_CONTEXT, appContext); binding.setVariable(GrailsApplication.APPLICATION_ID, appContext.getBean(GrailsApplication.APPLICATION_ID)); binding.setVariable(GroovyPage.SESSION, request.getSession()); binding.setVariable(GroovyPage.PARAMS, new GrailsParameterMap(request)); binding.setVariable(GroovyPage.OUT, out); } // Go through request attributes and add them to the binding as the model for (Enumeration attributeEnum = request.getAttributeNames(); attributeEnum.hasMoreElements();) { String key = (String) attributeEnum.nextElement(); if(!binding.getVariables().containsKey(key)) { binding.setVariable( key, request.getAttribute(key) ); } } for (Iterator i = additionalBinding.keySet().iterator(); i.hasNext();) { String key = (String)i.next(); binding.setVariable(key, additionalBinding.get(key)); } return binding; } // getBinding() | 50670 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50670/8f437ade5e2fd07aeb51b071528e08fc29c1a205/GroovyPagesTemplateEngine.java/clean/src/web/org/codehaus/groovy/grails/web/pages/GroovyPagesTemplateEngine.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
540,
4750,
15689,
29471,
12,
2940,
18572,
590,
16,
12446,
766,
16,
5497,
596,
13,
7734,
1216,
1860,
288,
5411,
368,
1000,
731,
326,
2728,
819,
5411,
15689,
5085,
273,
394,
15689,
5621,
13491,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4750,
15689,
29471,
12,
2940,
18572,
590,
16,
12446,
766,
16,
5497,
596,
13,
7734,
1216,
1860,
288,
5411,
368,
1000,
731,
326,
2728,
819,
5411,
15689,
5085,
273,
394,
15689,
5621,
13491,
... | ||
log.debug("Setting the JDBC connection to read only"); | if (log.isDebugEnabled()) log.debug("Setting the JDBC connection "+aConnection+" to read only, current state:"+ " isReadOnly="+aConnection.isReadOnly()+ ", isolation level="+aConnection.getTransactionIsolation()); aConnection.commit(); | public void _configureReadOnly(Connection aConnection) throws SQLException { log.debug("Setting the JDBC connection to read only"); aConnection.createStatement().executeUpdate(_readOnlySessionProperties()); } | 22541 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/22541/b9b367072692143167c25a2b75cbe91b803aa520/ERXDatabaseContextDelegate.java/clean/Common/Frameworks/ERExtensions/Sources/er/extensions/ERXDatabaseContextDelegate.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
389,
14895,
12066,
12,
1952,
279,
1952,
13,
1216,
6483,
288,
3639,
309,
261,
1330,
18,
291,
2829,
1526,
10756,
613,
18,
4148,
2932,
5568,
326,
16364,
1459,
13773,
69,
1952,
907... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
389,
14895,
12066,
12,
1952,
279,
1952,
13,
1216,
6483,
288,
3639,
309,
261,
1330,
18,
291,
2829,
1526,
10756,
613,
18,
4148,
2932,
5568,
326,
16364,
1459,
13773,
69,
1952,
907... |
System.out.println(new ClassFile(new DataInputStream(new FileInputStream(args[0]))).debugToString()); | System.out.println(new ClassFile(new DataInputStream(new FileInputStream(args[0]))).toString()); | public static void main(String[] args) throws Exception { if(args.length >= 2 && args[0].equals("copyto")) { File dest = new File(args[1]); dest.mkdirs(); for(int i=2;i<args.length;i++) { System.err.println("Copying " + args[i]); read(args[i]).dump(dest); } } else if (args.length==1) { if (args[0].endsWith(".class")) { System.out.println(new ClassFile(new DataInputStream(new FileInputStream(args[0]))).debugToString()); } else { InputStream is = Class.forName(args[0]).getClassLoader().getResourceAsStream(args[0].replace('.', '/')+".class"); System.out.println(new ClassFile(new DataInputStream(is)).debugToString()); } } else { /* Type.Class me = new Type.Class("Test"); ClassFile cg = new ClassFile("Test", "java.lang.Object", PUBLIC|SUPER|FINAL); FieldGen fg = cg.addField("foo", Type.INT, PUBLIC|STATIC); MethodGen mg = cg.addMethod("main", Type.VOID, new Type[]{Type.arrayType(Type.STRING)}, STATIC|PUBLIC); mg.setMaxLocals(1); mg.addPushConst(0); //mg.add(ISTORE_0); mg.add(PUTSTATIC, fieldRef(me, "foo", Type.INT)); int top = mg.size(); mg.add(GETSTATIC, cg.fieldRef(new Type.Class("java.lang.System"), "out", new Type.Class("java.io.PrintStream"))); //mg.add(ILOAD_0); mg.add(GETSTATIC, cg.fieldRef(me, "foo", Type.INT)); mg.add(INVOKEVIRTUAL, cg.methodRef(new Type.Class("java.io.PrintStream"), "println", Type.VOID, new Type[]{Type.INT})); //mg.add(IINC, new int[]{0, 1}); //mg.add(ILOAD_0); mg.add(GETSTATIC, cg.fieldRef(me, "foo", Type.INT)); mg.addPushConst(1); mg.add(IADD); mg.add(DUP); mg.add(PUTSTATIC, cg.fieldRef(me, "foo", Type.INT)); mg.addPushConst(10); mg.add(IF_ICMPLT, top); mg.add(RETURN); cg.dump("Test.class"); */ } } | 5774 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5774/02037f16d72e99a8838a0abcf6ff4f4dd1135f7e/ClassFile.java/buggy/upstream/build/classgen/src/org/ibex/classgen/ClassFile.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
1216,
1185,
288,
3639,
309,
12,
1968,
18,
2469,
1545,
576,
597,
833,
63,
20,
8009,
14963,
2932,
3530,
869,
6,
3719,
288,
5411,
1387,
1570,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
918,
2774,
12,
780,
8526,
833,
13,
1216,
1185,
288,
3639,
309,
12,
1968,
18,
2469,
1545,
576,
597,
833,
63,
20,
8009,
14963,
2932,
3530,
869,
6,
3719,
288,
5411,
1387,
1570,
... |
PluginJAR _jar = jEdit.getPluginJAR( dependents[i]); | PluginJAR _jar = jEdit.getPluginJAR(path); | private void unloadPluginJAR(PluginJAR jar) { String[] dependents = jar.getDependentPlugins(); for(int i = 0; i < dependents.length; i++) { PluginJAR _jar = jEdit.getPluginJAR( dependents[i]); if(_jar != null) { toLoad.add(dependents[i]); unloadPluginJAR(_jar); // clear cache file String cachePath = jar.getCachePath(); if(cachePath != null) new File(cachePath).delete(); } } jEdit.removePluginJAR(jar,false); } //}}} | 8690 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8690/3b7674a9c77c90989f8b3b0bc937514669fcd55c/Roster.java/clean/org/gjt/sp/jedit/pluginmgr/Roster.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
1152,
918,
27060,
3773,
46,
985,
12,
3773,
46,
985,
7334,
13,
202,
202,
95,
1082,
202,
780,
8526,
2447,
4877,
273,
7334,
18,
588,
18571,
9461,
5621,
1082,
202,
1884,
12,
474,
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,
3196,
202,
1152,
918,
27060,
3773,
46,
985,
12,
3773,
46,
985,
7334,
13,
202,
202,
95,
1082,
202,
780,
8526,
2447,
4877,
273,
7334,
18,
588,
18571,
9461,
5621,
1082,
202,
1884,
12,
474,
277,... |
if ( inputState.guessing==0 ) { openBlock_AST = (AST)currentAST.root; } | openBlock_AST = (AST)currentAST.root; | public final void openBlock() throws RecognitionException, TokenStreamException { returnAST = null; ASTPair currentAST = new ASTPair(); AST openBlock_AST = null; Token lc = null; AST lc_AST = null; lc = LT(1); if (inputState.guessing==0) { lc_AST = astFactory.create(lc); astFactory.makeASTRoot(currentAST, lc_AST); } match(LCURLY); nls(); if ( inputState.guessing==0 ) { lc_AST.setType(SLIST); } blockBody(EOF); if (inputState.guessing==0) { astFactory.addASTChild(currentAST, returnAST); } match(RCURLY); if ( inputState.guessing==0 ) { openBlock_AST = (AST)currentAST.root; } returnAST = openBlock_AST; } | 6462 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/6462/5c53aea8416ae7d318cf0157b4690ba71badb0f9/GroovyRecognizer.java/clean/src/main/org/codehaus/groovy/antlr/parser/GroovyRecognizer.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
1696,
1768,
1435,
1216,
9539,
16,
3155,
1228,
503,
288,
9506,
202,
2463,
9053,
273,
446,
31,
202,
202,
9053,
4154,
783,
9053,
273,
394,
9183,
4154,
5621,
202,
202,
9... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
727,
918,
1696,
1768,
1435,
1216,
9539,
16,
3155,
1228,
503,
288,
9506,
202,
2463,
9053,
273,
446,
31,
202,
202,
9053,
4154,
783,
9053,
273,
394,
9183,
4154,
5621,
202,
202,
9... |
if(rows*cols < count) { | if (rows*cols < count) { | void actionPerformed(ActionEvent e) { String cmd = e.getActionCommand(); int returnValue = -1; if(cmd.equals("Cut") || cmd.equals("Copy") || cmd.equals("Paste")) { JInternalFrame f = getSelectedFrame(); if(f != null && f instanceof ActionListener) { ((ActionListener)f).actionPerformed(e); } } else if(cmd.equals("Step Over")) { returnValue = STEP_OVER; } else if(cmd.equals("Step Into")) { returnValue = STEP_INTO; } else if(cmd.equals("Step Out")) { returnValue = STEP_OUT; } else if(cmd.equals("Go")) { returnValue = GO; } else if(cmd.equals("Break")) { doBreak(); } else if(cmd.equals("Run to Cursor")) { returnValue = RUN_TO_CURSOR; } else if(cmd.equals("Exit")) { Exit(); } else if(cmd.equals("Open")) { Scriptable scope = getScope(); if(scope == null) { MessageDialogWrapper.showMessageDialog(this, "Can't compile scripts: no scope available", "Open", JOptionPane.ERROR_MESSAGE); } else { String fileName = chooseFile("Select a file to compile"); if(fileName != null) { new Thread(new OpenFile(this, scope, fileName)).start(); } } } else if(cmd.equals("Load")) { Scriptable scope = getScope(); if(scope == null) { MessageDialogWrapper.showMessageDialog(this, "Can't run scripts: no scope available", "Run", JOptionPane.ERROR_MESSAGE); } else { String fileName = chooseFile("Select a file to execute"); if(fileName != null) { new Thread(new LoadFile(this, scope, fileName)).start(); } } } else if(cmd.equals("More Windows...")) { MoreWindows dlg = new MoreWindows(this, fileWindows, "Window", "Files"); dlg.showDialog(this); } else if(cmd.equals("Console")) { if(console.isIcon()) { desk.getDesktopManager().deiconifyFrame(console); } console.show(); desk.getDesktopManager().activateFrame(console); console.consoleTextArea.requestFocus(); } else if(cmd.equals("Cut")) { } else if(cmd.equals("Copy")) { } else if(cmd.equals("Paste")) { } else if(cmd.equals("Go to function...")) { FindFunction dlg = new FindFunction(this, functionMap, "Go to function", "Function"); dlg.showDialog(this); } else if(cmd.equals("Tile")) { JInternalFrame[] frames = desk.getAllFrames(); int count = frames.length; int rows, cols; rows = cols = (int)Math.sqrt(count); if(rows*cols < count) { cols++; if(rows * cols < count) { rows++; } } Dimension size = desk.getSize(); int w = size.width/cols; int h = size.height/rows; int x = 0; int y = 0; for(int i = 0; i < rows; i++) { for(int j = 0; j < cols; j++) { int index = (i*cols) + j; if(index >= frames.length) { break; } JInternalFrame f = frames[index]; try { f.setIcon(false); f.setMaximum(false); } catch (Exception exc) { } desk.getDesktopManager().setBoundsForFrame(f, x, y, w, h); x += w; } y += h; x = 0; } } else if(cmd.equals("Cascade")) { JInternalFrame[] frames = desk.getAllFrames(); int count = frames.length; int x, y, w, h; x = y = 0; h = desk.getHeight(); int d = h / count; if(d > 30) d = 30; for(int i = count -1; i >= 0; i--, x += d, y += d) { JInternalFrame f = frames[i]; try { f.setIcon(false); f.setMaximum(false); } catch (Exception exc) { } Dimension dimen = f.getPreferredSize(); w = dimen.width; h = dimen.height; desk.getDesktopManager().setBoundsForFrame(f, x, y, w, h); } } else { Object obj = getFileWindow(cmd); if(obj != null) { FileWindow w = (FileWindow)obj; try { if(w.isIcon()) { w.setIcon(false); } w.setVisible(true); w.moveToFront(); w.setSelected(true); } catch(Exception exc) { } } } if(returnValue != -1) { if(currentWindow != null) currentWindow.setPosition(-1); synchronized(monitor) { this.returnValue = returnValue; monitor.notify(); } } } | 51996 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51996/b9766e81693411fa600b26b9a0763dcf621b2770/Main.java/buggy/js/rhino/toolsrc/org/mozilla/javascript/tools/debugger/Main.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
918,
26100,
12,
1803,
1133,
425,
13,
288,
3639,
514,
1797,
273,
425,
18,
588,
1803,
2189,
5621,
3639,
509,
7750,
273,
300,
21,
31,
3639,
309,
12,
4172,
18,
14963,
2932,
15812,
7923,
747... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
26100,
12,
1803,
1133,
425,
13,
288,
3639,
514,
1797,
273,
425,
18,
588,
1803,
2189,
5621,
3639,
509,
7750,
273,
300,
21,
31,
3639,
309,
12,
4172,
18,
14963,
2932,
15812,
7923,
747... |
List results = new ArrayList(); | Iterator it = subsetters.iterator(); | public StringTree accept(Channel channel, ProxyNetworkAccess network) throws Exception { List results = new ArrayList(); Channel[] allChans = network.retrieve_for_station(channel.my_site.my_station.get_id()); for(int i = 0; i < allChans.length; i++) { StringTree result = super.accept(allChans[i], network); results.add(result); if(result.isSuccess()) { return new StringTreeBranch(this, true, (StringTree[])results.toArray(new StringTree[0])); } } return new StringTreeBranch(this, false, (StringTree[])results.toArray(new StringTree[0])); } | 45996 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/45996/23f155dc82814721f093fc184e8a7b542a0e403a/StationHas.java/buggy/src/edu/sc/seis/sod/subsetter/channel/StationHas.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
2471,
2791,
12,
2909,
1904,
16,
7659,
3906,
1862,
2483,
13,
5411,
1216,
1185,
288,
3639,
4498,
518,
273,
7931,
5432,
18,
9838,
5621,
3639,
5307,
8526,
777,
782,
634,
273,
2483,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2471,
2791,
12,
2909,
1904,
16,
7659,
3906,
1862,
2483,
13,
5411,
1216,
1185,
288,
3639,
4498,
518,
273,
7931,
5432,
18,
9838,
5621,
3639,
5307,
8526,
777,
782,
634,
273,
2483,... |
setContentDescription(""); | setContentDescription(""); | void updateTitle(Object newInput) { IConfigurationElement config = getConfigurationElement(); if (config == null) return; if (newInput == null || newInput.equals(PDECore.getDefault().getModelManager())) { setContentDescription(""); // restore old setTitleToolTip(getTitle()); } else { String viewName = config.getAttribute("name"); //$NON-NLS-1$ String name = ((LabelProvider) treeViewer.getLabelProvider()).getText(newInput); setContentDescription(viewName + ": " + name); //$NON-NLS-1$ setTitleToolTip(getInputPath(newInput)); } } | 8783 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8783/3764ae2a129c37898e1dad333a23ffc8ee00a722/PluginsView.java/buggy/ui/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/view/PluginsView.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
6459,
1089,
4247,
12,
921,
394,
1210,
13,
288,
202,
202,
45,
1750,
1046,
642,
273,
10316,
1046,
5621,
202,
202,
430,
261,
1425,
422,
446,
13,
1082,
202,
2463,
31,
9506,
202,
430,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
6459,
1089,
4247,
12,
921,
394,
1210,
13,
288,
202,
202,
45,
1750,
1046,
642,
273,
10316,
1046,
5621,
202,
202,
430,
261,
1425,
422,
446,
13,
1082,
202,
2463,
31,
9506,
202,
430,
... |
System.out.println("Ne devrait pas arriver"); assertTrue(false); | fail("Ne devrait pas arriver"); | public void testLoadPreferences() { // on cree un fichier temp pour etre sur de son existance File f = createTempFile(); try { PreferencesManager.getInstance().setPreference("toto", f.getAbsolutePath()); PreferencesManager.getInstance().storePreferences(); PreferencesManager.getInstance().removePreference("toto"); assertNull(PreferencesManager.getInstance().getPreference("toto")); PreferencesManager.getInstance().loadPreferences(); assertTrue(PreferencesManager.getInstance().getPreference("toto") .equals(f.getAbsolutePath())); } catch (Exception e) { System.out.println("Ne devrait pas arriver"); //TODO assertTrue(false) assertTrue(false); e.printStackTrace(); } } | 9158 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9158/fb348e0d05f3cd190cc56cb0db2b3d5be833594f/PreferencesManagerTest.java/clean/PAGOD/src/test/pagod/configurator/control/PreferencesManagerTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
2563,
12377,
1435,
565,
288,
3639,
368,
603,
276,
992,
640,
284,
1354,
2453,
1906,
24601,
3393,
266,
5056,
443,
18882,
1005,
1359,
3639,
1387,
284,
273,
30106,
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,
2563,
12377,
1435,
565,
288,
3639,
368,
603,
276,
992,
640,
284,
1354,
2453,
1906,
24601,
3393,
266,
5056,
443,
18882,
1005,
1359,
3639,
1387,
284,
273,
30106,
5621,
3639,
... |
fileSetManager.delete( fs ); | fileSetManager.delete( fs ); | static public void removeDirectory( File dir ) throws IOException { if ( dir != null ) { FileSetManager fileSetManager = new FileSetManager( new SilentLog(), false ); FileSet fs = new FileSet(); fs.setDirectory( dir.getPath() ); fs.addInclude( "**/**" ); fileSetManager.delete( fs ); } } | 51807 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51807/cc3a01ab903ce7a1610784db39e6913daeb39597/DependencyTestUtils.java/clean/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/DependencyTestUtils.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
760,
1071,
918,
1206,
2853,
12,
1387,
1577,
262,
1216,
1860,
565,
288,
3639,
309,
261,
1577,
480,
446,
262,
3639,
288,
5411,
1387,
694,
1318,
585,
694,
1318,
273,
394,
1387,
694,
1318,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1071,
918,
1206,
2853,
12,
1387,
1577,
262,
1216,
1860,
565,
288,
3639,
309,
261,
1577,
480,
446,
262,
3639,
288,
5411,
1387,
694,
1318,
585,
694,
1318,
273,
394,
1387,
694,
1318,
... |
public String toFormulaString(SheetReferences refs) | public String toFormulaString(Workbook book) | public String toFormulaString(SheetReferences refs) { return "+"; } | 509 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/509/3a17ddd5d43b1a648d653abb0a42371ac01d4b3e/UnaryPlusPtg.java/clean/src/java/org/apache/poi/hssf/record/formula/UnaryPlusPtg.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
358,
14972,
780,
12,
23345,
6978,
13,
565,
288,
3639,
327,
17487,
31,
565,
289,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
358,
14972,
780,
12,
23345,
6978,
13,
565,
288,
3639,
327,
17487,
31,
565,
289,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
String error = fAttrGrp.validRestrictionOf(baseType.getAttrGrp()); if (error != null) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError(error, new Object[]{fName}, complexContent); | Object[] errArgs = fAttrGrp.validRestrictionOf(fName, baseType.getAttrGrp()); if (errArgs != null) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError((String)errArgs[errArgs.length-1], errArgs, complexContent); | private void traverseComplexContent(Element complexContentElement, boolean mixedOnType, XSDocumentInfo schemaDoc, SchemaGrammar grammar) throws ComplexTypeRecoverableError { Object[] complexContentAttrValues = fAttrChecker.checkAttributes(complexContentElement, false, schemaDoc); // ----------------------------------------------------------------------- // Determine if this is mixed content // ----------------------------------------------------------------------- boolean mixedContent = mixedOnType; Boolean mixedAtt = (Boolean) complexContentAttrValues[XSAttributeChecker.ATTIDX_MIXED]; if (mixedAtt != null) { mixedContent = mixedAtt.booleanValue(); } // ----------------------------------------------------------------------- // Since the type must have complex content, set the simple type validators // to null // ----------------------------------------------------------------------- fXSSimpleType = null; Element complexContent = DOMUtil.getFirstChildElement(complexContentElement); if (complexContent != null) { // traverse annotation if any if (DOMUtil.getLocalName(complexContent).equals(SchemaSymbols.ELT_ANNOTATION)) { traverseAnnotationDecl(complexContent, complexContentAttrValues, false, schemaDoc); complexContent = DOMUtil.getNextSiblingElement(complexContent); } } // If there are no children, return if (complexContent==null) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("src-ct.0.2", new Object[]{fName,SchemaSymbols.ELT_COMPLEXCONTENT}, complexContentElement); } // ----------------------------------------------------------------------- // The content should be either "restriction" or "extension" // ----------------------------------------------------------------------- String complexContentName = DOMUtil.getLocalName(complexContent); if (complexContentName.equals(SchemaSymbols.ELT_RESTRICTION)) fDerivedBy = XSConstants.DERIVATION_RESTRICTION; else if (complexContentName.equals(SchemaSymbols.ELT_EXTENSION)) fDerivedBy = XSConstants.DERIVATION_EXTENSION; else { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("src-ct.0.1", new Object[]{fName, complexContentName}, complexContent); } Element elemTmp = DOMUtil.getNextSiblingElement(complexContent); if (elemTmp != null) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); String siblingName = DOMUtil.getLocalName(elemTmp); throw new ComplexTypeRecoverableError("src-ct.0.1", new Object[]{fName, siblingName}, elemTmp); } Object[] derivationTypeAttrValues = fAttrChecker.checkAttributes(complexContent, false, schemaDoc); QName baseTypeName = (QName) derivationTypeAttrValues[XSAttributeChecker.ATTIDX_BASE]; // ----------------------------------------------------------------------- // Need a base type. Check that it's a complex type // ----------------------------------------------------------------------- if (baseTypeName==null) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("src-ct.0.3", new Object[]{fName}, complexContent); } XSTypeDefinition type = (XSTypeDefinition)fSchemaHandler.getGlobalDecl(schemaDoc, XSDHandler.TYPEDECL_TYPE, baseTypeName, complexContent); if (type==null) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError(); } if (! (type instanceof XSComplexTypeDecl)) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("src-ct.1", new Object[]{fName}, complexContent); } XSComplexTypeDecl baseType = (XSComplexTypeDecl)type; fBaseType = baseType; // ----------------------------------------------------------------------- // Check that the base permits the derivation // ----------------------------------------------------------------------- if ((baseType.getFinal() & fDerivedBy)!=0) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); String errorKey = (fDerivedBy==XSConstants.DERIVATION_EXTENSION) ? "cos-ct-extends.1.1" : "derivation-ok-restriction.1"; throw new ComplexTypeRecoverableError(errorKey, new Object[]{fName}, complexContent); } // ----------------------------------------------------------------------- // Skip over any potential annotations // ----------------------------------------------------------------------- complexContent = DOMUtil.getFirstChildElement(complexContent); if (complexContent != null) { // traverse annotation if any if (DOMUtil.getLocalName(complexContent).equals(SchemaSymbols.ELT_ANNOTATION)) { traverseAnnotationDecl(complexContent, derivationTypeAttrValues, false, schemaDoc); complexContent = DOMUtil.getNextSiblingElement(complexContent); } if (complexContent !=null && DOMUtil.getLocalName(complexContent).equals(SchemaSymbols.ELT_ANNOTATION)){ fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("src-ct.0.1", new Object[]{fName,SchemaSymbols.ELT_ANNOTATION}, complexContent); } } // ----------------------------------------------------------------------- // Process the content. Note: should I try to catch any complexType errors // here in order to return the attr array? // ----------------------------------------------------------------------- try { processComplexContent(complexContent, mixedContent, true, schemaDoc, grammar); } catch (ComplexTypeRecoverableError e) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw e; } // ----------------------------------------------------------------------- // Compose the final content and attribute uses // ----------------------------------------------------------------------- XSParticleDecl baseContent = (XSParticleDecl)baseType.getParticle(); if (fDerivedBy==XSConstants.DERIVATION_RESTRICTION) { // This is an RESTRICTION // N.B. derivation-ok-restriction.5.2 is checked under schema // full checking. That's because we need to wait until locals are // traversed so that occurrence information is correct. if (fContentType == XSComplexTypeDecl.CONTENTTYPE_MIXED && baseType.getContentType() != XSComplexTypeDecl.CONTENTTYPE_MIXED) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("derivation-ok-restriction.5.3.1.2", new Object[]{fName}, complexContent); } try { mergeAttributes(baseType.getAttrGrp(), fAttrGrp, fName, false, complexContent); } catch (ComplexTypeRecoverableError e) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw e; } // Remove prohibited uses. Must be done after merge for RESTRICTION. fAttrGrp.removeProhibitedAttrs(); if (baseType != SchemaGrammar.fAnyType) { String error = fAttrGrp.validRestrictionOf(baseType.getAttrGrp()); if (error != null) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError(error, new Object[]{fName}, complexContent); } } } else { // This is an EXTENSION // Create the particle if (fParticle == null) { fContentType = baseType.getContentType(); fXSSimpleType = (XSSimpleType)baseType.getSimpleType(); fParticle = baseContent; } else if (baseType.getContentType() == XSComplexTypeDecl.CONTENTTYPE_EMPTY) { } else { // // Check if the contentType of the base is consistent with the new type // cos-ct-extends.1.4.3.2 if (fContentType == XSComplexTypeDecl.CONTENTTYPE_ELEMENT && baseType.getContentType() != XSComplexTypeDecl.CONTENTTYPE_ELEMENT || fContentType == XSComplexTypeDecl.CONTENTTYPE_MIXED && baseType.getContentType() != XSComplexTypeDecl.CONTENTTYPE_MIXED) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("cos-ct-extends.1.4.3.2.2.1", new Object[]{fName}, complexContent); } // if the content of either type is an "all" model group, error. if (fParticle.fType == XSParticleDecl.PARTICLE_MODELGROUP && ((XSModelGroupImpl)fParticle.fValue).fCompositor == XSModelGroupImpl.MODELGROUP_ALL || ((XSParticleDecl)baseType.getParticle()).fType == XSParticleDecl.PARTICLE_MODELGROUP && ((XSModelGroupImpl)(((XSParticleDecl)baseType.getParticle())).fValue).fCompositor == XSModelGroupImpl.MODELGROUP_ALL) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw new ComplexTypeRecoverableError("cos-all-limited.1.2", null, complexContent); } // the "sequence" model group to contain both particles XSModelGroupImpl group = new XSModelGroupImpl(); group.fCompositor = XSModelGroupImpl.MODELGROUP_SEQUENCE; group.fParticleCount = 2; group.fParticles = new XSParticleDecl[2]; group.fParticles[0] = (XSParticleDecl)baseType.getParticle(); group.fParticles[1] = fParticle; // the particle to contain the above sequence XSParticleDecl particle = new XSParticleDecl(); particle.fType = XSParticleDecl.PARTICLE_MODELGROUP; particle.fValue = group; fParticle = particle; } // Remove prohibited uses. Must be done before merge for EXTENSION. fAttrGrp.removeProhibitedAttrs(); try { mergeAttributes(baseType.getAttrGrp(), fAttrGrp, fName, true, complexContent); } catch (ComplexTypeRecoverableError e) { fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); throw e; } } // and *finally* we can legitimately return the attributes! fAttrChecker.returnAttrArray(complexContentAttrValues, schemaDoc); fAttrChecker.returnAttrArray(derivationTypeAttrValues, schemaDoc); } // end of traverseComplexContent | 46079 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/46079/08452497d5ddc107ce0c88dafa4af418a8162487/XSDComplexTypeTraverser.java/clean/src/org/apache/xerces/impl/xs/traversers/XSDComplexTypeTraverser.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
10080,
12795,
1350,
12,
1046,
7233,
1350,
1046,
16,
4766,
3639,
1250,
7826,
1398,
559,
16,
1139,
55,
2519,
966,
1963,
1759,
16,
4766,
3639,
4611,
18576,
6473,
13,
565,
1216,
16... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
918,
10080,
12795,
1350,
12,
1046,
7233,
1350,
1046,
16,
4766,
3639,
1250,
7826,
1398,
559,
16,
1139,
55,
2519,
966,
1963,
1759,
16,
4766,
3639,
4611,
18576,
6473,
13,
565,
1216,
16... |
project.open(new SubProgressMonitor(monitor, 1000)); | project.open(IResource.BACKGROUND_REFRESH, new SubProgressMonitor(monitor, 1000)); | IProject createExistingProject() { String projectName = projectNameField.getText(); final IWorkspace workspace = ResourcesPlugin.getWorkspace(); final IProject project = workspace.getRoot().getProject(projectName); if (this.description == null) { this.description = workspace.newProjectDescription(projectName); IPath locationPath = getLocationPath(); //If it is under the root use the default location if (isPrefixOfRoot(locationPath)) this.description.setLocation(null); else this.description.setLocation(locationPath); } else this.description.setName(projectName); // create the new project operation WorkspaceModifyOperation op = new WorkspaceModifyOperation() { protected void execute(IProgressMonitor monitor) throws CoreException { monitor.beginTask("", 2000); //$NON-NLS-1$ project.create(description, new SubProgressMonitor(monitor, 1000)); if (monitor.isCanceled()) throw new OperationCanceledException(); project.open(new SubProgressMonitor(monitor, 1000)); } }; // run the new project creation operation try { getContainer().run(true, true, op); } catch (InterruptedException e) { return null; } catch (InvocationTargetException e) { // ie.- one of the steps resulted in a core exception Throwable t = e.getTargetException(); if (t instanceof CoreException) { if (((CoreException) t).getStatus().getCode() == IResourceStatus.CASE_VARIANT_EXISTS) { MessageDialog .openError( getShell(), DataTransferMessages .getString("WizardExternalProjectImportPage.errorMessage"), //$NON-NLS-1$ DataTransferMessages .getString("WizardExternalProjectImportPage.caseVariantExistsError") //$NON-NLS-1$, ); } else { ErrorDialog .openError( getShell(), DataTransferMessages .getString("WizardExternalProjectImportPage.errorMessage"), //$NON-NLS-1$ null, ((CoreException) t).getStatus()); } } return null; } return project; } | 58148 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/58148/f485f50c8b8639db05cbf435b2e5d262f6ad8b14/WizardExternalProjectImportPage.java/buggy/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/wizards/datatransfer/WizardExternalProjectImportPage.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
467,
4109,
752,
9895,
4109,
1435,
288,
3639,
514,
17234,
273,
17234,
974,
18,
588,
1528,
5621,
3639,
727,
467,
8241,
6003,
273,
8128,
3773,
18,
588,
8241,
5621,
3639,
727,
467,
4109,
1984... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
467,
4109,
752,
9895,
4109,
1435,
288,
3639,
514,
17234,
273,
17234,
974,
18,
588,
1528,
5621,
3639,
727,
467,
8241,
6003,
273,
8128,
3773,
18,
588,
8241,
5621,
3639,
727,
467,
4109,
1984... |
public int[] getRandom(int max, int count, String annotation); | public int getRandom(int max, String annotation); | public int[] getRandom(int max, int count, String annotation); | 8339 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8339/94dcbc456ee416c732facb9e512450d43ee98531/IDelegateBridge.java/buggy/src/games/strategy/engine/delegate/IDelegateBridge.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
509,
8526,
20581,
12,
474,
943,
16,
509,
1056,
16,
514,
3204,
1769,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
509,
8526,
20581,
12,
474,
943,
16,
509,
1056,
16,
514,
3204,
1769,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
log().error("Disconnected while completing handshake"); | log().debug("Disconnected while completing handshake"); | public boolean completeHandshake() { if (!isConnected()) { return false; } boolean thisHandshakeCompleted = true; synchronized (peerInitalizeLock) { if (!isConnected()) { log().warn("Disconnected while completing handshake"); return false; } // Send node informations now // Send joined folders to synchronize FolderList folderList = new FolderList(getController() .getFolderRepository().getJoinedFolderInfos(), peer .getRemoteMagicId()); peer.sendMessageAsynchron(folderList, null); // Send our transfer status peer.sendMessageAsynchron(getController().getTransferManager() .getStatus(), null); } // My messages sent, now wait for his folder list. waitForFolderList(); // Create request for nodelist. RequestNodeList request = getController().getNodeManager() .createDefaultNodeListRequestMessage(); synchronized (peerInitalizeLock) { if (!isConnected()) { log().error("Disconnected while completing handshake"); return false; } if (!isInteresting()) { log().warn("Rejected, Node not interesting"); // Tell remote side try { peer.sendMessage(new Problem("You are boring", true, Problem.YOU_ARE_BORING)); } catch (ConnectionException e) { log().verbose(e); } thisHandshakeCompleted = false; } else { // Send request for nodelist. peer.sendMessageAsynchron(request, null); } } // Handshaked ? handshaked = thisHandshakeCompleted && isConnected(); if (handshaked) { // Reset things connectionRetries = 0; unableToConnect = false; // if (logEnabled) { log().info( "Connected (" + getController().getNodeManager().countConnectedNodes() + " total)"); // } // Supernode <-> Supernode communication on public networking if (getController().isPublicNetworking() && isSupernode() && getController().getMySelf().isSupernode()) { sendMessageAsynchron(RequestNetworkFolderList.COMPLETE_LIST, "Unable to request network folder list"); } // Inform nodemanger about it getController().getNodeManager().onlineStateChanged(this); if (getController().isVerbose()) { // Running in verbose mode, directly request node information sendMessageAsynchron(new RequestNodeInformation(), null); } } else { // Not handshaked, shutdown shutdown(); } return handshaked; } | 51438 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51438/3319dac328eefdd841242b1025359e53649a8b1d/Member.java/clean/src/main/de/dal33t/powerfolder/Member.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1250,
3912,
14545,
1435,
288,
3639,
309,
16051,
291,
8932,
10756,
288,
5411,
327,
629,
31,
3639,
289,
3639,
1250,
333,
14545,
9556,
273,
638,
31,
3639,
3852,
261,
12210,
2570,
287,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3912,
14545,
1435,
288,
3639,
309,
16051,
291,
8932,
10756,
288,
5411,
327,
629,
31,
3639,
289,
3639,
1250,
333,
14545,
9556,
273,
638,
31,
3639,
3852,
261,
12210,
2570,
287,
... |
this(packageName, packageName + "." + className, | this(packageName, className, | public NameEntry(String packageName, String className) { this(packageName, packageName + "." + className, XmlTools.xmlTagFromClassName(className, "State", false)); } | 51914 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/51914/9849d18490ad28fd5bcc1863883574d1c8a19f6f/TranslationSpace.java/buggy/cm_metadata/ecologylab/xml/TranslationSpace.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
225,
1071,
1770,
1622,
12,
780,
9929,
16,
514,
2658,
13,
202,
225,
288,
1082,
333,
12,
5610,
461,
16,
9929,
397,
4585,
397,
2658,
16,
9506,
225,
5714,
10348,
18,
2902,
1805,
1265,
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,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
225,
1071,
1770,
1622,
12,
780,
9929,
16,
514,
2658,
13,
202,
225,
288,
1082,
333,
12,
5610,
461,
16,
9929,
397,
4585,
397,
2658,
16,
9506,
225,
5714,
10348,
18,
2902,
1805,
1265,
3834... |
_publishingLeaseSets = new HashSet(8); | _publishingLeaseSets = new HashMap(8); | public KademliaNetworkDatabaseFacade(RouterContext context) { _context = context; _log = _context.logManager().getLog(KademliaNetworkDatabaseFacade.class); _initialized = false; _peerSelector = new PeerSelector(_context); _publishingLeaseSets = new HashSet(8); _lastExploreNew = 0; _knownRouters = 0; _activeRequests = new HashMap(8); _enforceNetId = DEFAULT_ENFORCE_NETID; } | 27493 /local/tlutelli/issta_data/temp/all_java2context/java/2006_temp/2006/27493/bc626ece2d2f61e1246a0c597f733962ed58b0db/KademliaNetworkDatabaseFacade.java/clean/router/java/src/net/i2p/router/networkdb/kademlia/KademliaNetworkDatabaseFacade.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
1475,
2486,
81,
549,
69,
3906,
4254,
12467,
12,
8259,
1042,
819,
13,
288,
3639,
389,
2472,
273,
819,
31,
3639,
389,
1330,
273,
389,
2472,
18,
1330,
1318,
7675,
588,
1343,
12,
47,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1475,
2486,
81,
549,
69,
3906,
4254,
12467,
12,
8259,
1042,
819,
13,
288,
3639,
389,
2472,
273,
819,
31,
3639,
389,
1330,
273,
389,
2472,
18,
1330,
1318,
7675,
588,
1343,
12,
47,
... |
String l_pStatus = encoding.decode(pgStream.Receive(l_len-4)); | String name = pgStream.ReceiveString(encoding); String value = pgStream.ReceiveString(encoding); | private void openConnectionV3(String p_host, int p_port, Properties p_info, String p_database, String p_url, Driver p_d, String p_password) throws SQLException { PGProtocolVersionMajor = 3; if (Driver.logDebug) Driver.debug("Using Protocol Version3"); // Now we need to construct and send an ssl startup packet try { if (useSSL) { if (Driver.logDebug) Driver.debug("Asking server if it supports ssl"); pgStream.SendInteger(8,4); pgStream.SendInteger(80877103,4); // now flush the ssl packets to the backend pgStream.flush(); // Now get the response from the backend, either an error message // or an authentication request int beresp = pgStream.ReceiveChar(); if (Driver.logDebug) Driver.debug("Server response was (S=Yes,N=No): "+(char)beresp); switch (beresp) { case 'E': // An error occured, so pass the error message to the // user. // // The most common one to be thrown here is: // "User authentication failed" // throw new PSQLException("postgresql.con.misc", PSQLState.CONNECTION_REJECTED, pgStream.ReceiveString(encoding)); case 'N': // Server does not support ssl throw new PSQLException("postgresql.con.sslnotsupported", PSQLState.CONNECTION_FAILURE); case 'S': // Server supports ssl if (Driver.logDebug) Driver.debug("server does support ssl"); Driver.makeSSL(pgStream); break; default: throw new PSQLException("postgresql.con.sslfail", PSQLState.CONNECTION_FAILURE); } } } catch (IOException e) { throw new PSQLException("postgresql.con.failed", PSQLState.CONNECTION_UNABLE_TO_CONNECT, e); } // Now we need to construct and send a startup packet try { new StartupPacket(PGProtocolVersionMajor, PGProtocolVersionMinor, PG_USER, p_database).writeTo(pgStream); // now flush the startup packets to the backend pgStream.flush(); // Now get the response from the backend, either an error message // or an authentication request int areq = -1; // must have a value here do { int beresp = pgStream.ReceiveChar(); String salt = null; byte [] md5Salt = new byte[4]; switch (beresp) { case 'E': // An error occured, so pass the error message to the // user. // // The most common one to be thrown here is: // "User authentication failed" // int l_elen = pgStream.ReceiveIntegerR(4); if (l_elen > 30000) { //if the error length is > than 30000 we assume this is really a v2 protocol //server so try again with a v2 connection //need to create a new connection and try again try { pgStream = new PGStream(p_host, p_port); } catch (ConnectException cex) { // Added by Peter Mount <peter@retep.org.uk> // ConnectException is thrown when the connection cannot be made. // we trap this an return a more meaningful message for the end user throw new PSQLException ("postgresql.con.refused", PSQLState.CONNECTION_REJECTED); } catch (IOException e) { throw new PSQLException ("postgresql.con.failed", PSQLState.CONNECTION_UNABLE_TO_CONNECT, e); } openConnectionV2(p_host, p_port, p_info, p_database, p_url, p_d, p_password); return; } throw new PSQLException("postgresql.con.misc", PSQLState.CONNECTION_REJECTED, PSQLException.parseServerError(encoding.decode(pgStream.Receive(l_elen-4)))); case 'R': // Get the message length int l_msgLen = pgStream.ReceiveIntegerR(4); // Get the type of request areq = pgStream.ReceiveIntegerR(4); // Get the crypt password salt if there is one if (areq == AUTH_REQ_CRYPT) { byte[] rst = new byte[2]; rst[0] = (byte)pgStream.ReceiveChar(); rst[1] = (byte)pgStream.ReceiveChar(); salt = new String(rst, 0, 2); if (Driver.logDebug) Driver.debug("Crypt salt=" + salt); } // Or get the md5 password salt if there is one if (areq == AUTH_REQ_MD5) { md5Salt[0] = (byte)pgStream.ReceiveChar(); md5Salt[1] = (byte)pgStream.ReceiveChar(); md5Salt[2] = (byte)pgStream.ReceiveChar(); md5Salt[3] = (byte)pgStream.ReceiveChar(); if (Driver.logDebug) { String md5SaltString = ""; for (int i=0; i<md5Salt.length; i++) { md5SaltString += " " + md5Salt[i]; } Driver.debug("MD5 salt=" + md5SaltString); } } // now send the auth packet switch (areq) { case AUTH_REQ_OK: break; case AUTH_REQ_KRB4: if (Driver.logDebug) Driver.debug("postgresql: KRB4"); throw new PSQLException("postgresql.con.kerb4", PSQLState.CONNECTION_REJECTED); case AUTH_REQ_KRB5: if (Driver.logDebug) Driver.debug("postgresql: KRB5"); throw new PSQLException("postgresql.con.kerb5", PSQLState.CONNECTION_REJECTED); case AUTH_REQ_SCM: if (Driver.logDebug) Driver.debug("postgresql: SCM"); throw new PSQLException("postgresql.con.scm", PSQLState.CONNECTION_REJECTED); case AUTH_REQ_PASSWORD: if (Driver.logDebug) Driver.debug("postgresql: PASSWORD"); pgStream.SendChar('p'); pgStream.SendInteger(5 + p_password.length(), 4); pgStream.Send(p_password.getBytes()); pgStream.SendChar(0); pgStream.flush(); break; case AUTH_REQ_CRYPT: if (Driver.logDebug) Driver.debug("postgresql: CRYPT"); String crypted = UnixCrypt.crypt(salt, p_password); pgStream.SendChar('p'); pgStream.SendInteger(5 + crypted.length(), 4); pgStream.Send(crypted.getBytes()); pgStream.SendChar(0); pgStream.flush(); break; case AUTH_REQ_MD5: if (Driver.logDebug) Driver.debug("postgresql: MD5"); byte[] digest = MD5Digest.encode(PG_USER, p_password, md5Salt); pgStream.SendChar('p'); pgStream.SendInteger(5 + digest.length, 4); pgStream.Send(digest); pgStream.SendChar(0); pgStream.flush(); break; default: throw new PSQLException("postgresql.con.auth", PSQLState.CONNECTION_REJECTED, new Integer(areq)); } break; default: throw new PSQLException("postgresql.con.authfail", PSQLState.CONNECTION_REJECTED); } } while (areq != AUTH_REQ_OK); } catch (IOException e) { throw new PSQLException("postgresql.con.failed", PSQLState.CONNECTION_UNABLE_TO_CONNECT, e); } int beresp; do { beresp = pgStream.ReceiveChar(); switch (beresp) { case 'Z': //ready for query break; case 'K': int l_msgLen = pgStream.ReceiveIntegerR(4); if (l_msgLen != 12) throw new PSQLException("postgresql.con.setup", PSQLState.CONNECTION_UNABLE_TO_CONNECT); pid = pgStream.ReceiveIntegerR(4); ckey = pgStream.ReceiveIntegerR(4); break; case 'E': int l_elen = pgStream.ReceiveIntegerR(4); throw new PSQLException("postgresql.con.backend", PSQLState.CONNECTION_UNABLE_TO_CONNECT, PSQLException.parseServerError(encoding.decode(pgStream.Receive(l_elen-4)))); case 'N': int l_nlen = pgStream.ReceiveIntegerR(4); addWarning(encoding.decode(pgStream.Receive(l_nlen-4))); break; case 'S': //TODO: handle parameter status messages int l_len = pgStream.ReceiveIntegerR(4); String l_pStatus = encoding.decode(pgStream.Receive(l_len-4)); if (Driver.logDebug) Driver.debug("ParameterStatus="+ l_pStatus); break; default: if (Driver.logDebug) Driver.debug("invalid state="+ (char)beresp); throw new PSQLException("postgresql.con.setup", PSQLState.CONNECTION_UNABLE_TO_CONNECT); } } while (beresp != 'Z'); // read ReadyForQuery if (pgStream.ReceiveIntegerR(4) != 5) throw new PSQLException("postgresql.con.setup", PSQLState.CONNECTION_UNABLE_TO_CONNECT); //TODO: handle transaction status char l_tStatus = (char)pgStream.ReceiveChar(); // "pg_encoding_to_char(1)" will return 'EUC_JP' for a backend compiled with multibyte, // otherwise it's hardcoded to 'SQL_ASCII'. // If the backend doesn't know about multibyte we can't assume anything about the encoding // used, so we denote this with 'UNKNOWN'. //Note: begining with 7.2 we should be using pg_client_encoding() which //is new in 7.2. However it isn't easy to conditionally call this new //function, since we don't yet have the information as to what server //version we are talking to. Thus we will continue to call //getdatabaseencoding() until we drop support for 7.1 and older versions //or until someone comes up with a conditional way to run one or //the other function depending on server version that doesn't require //two round trips to the server per connection final String encodingQuery = "case when pg_encoding_to_char(1) = 'SQL_ASCII' then 'UNKNOWN' else getdatabaseencoding() end"; // Set datestyle and fetch db encoding in a single call, to avoid making // more than one round trip to the backend during connection startup. BaseResultSet resultSet = execSQL("set datestyle to 'ISO'; select version(), " + encodingQuery + ";"); if (! resultSet.next()) { throw new PSQLException("postgresql.con.failed.bad.encoding", PSQLState.CONNECTION_UNABLE_TO_CONNECT); } String version = resultSet.getString(1); dbVersionNumber = extractVersionNumber(version); String dbEncoding = resultSet.getString(2); encoding = Encoding.getEncoding(dbEncoding, p_info.getProperty("charSet")); //In 7.3 we are forced to do a second roundtrip to handle the case //where a database may not be running in autocommit mode //jdbc by default assumes autocommit is on until setAutoCommit(false) //is called. Therefore we need to ensure a new connection is //initialized to autocommit on. //We also set the client encoding so that the driver only needs //to deal with utf8. We can only do this in 7.3 because multibyte //support is now always included if (haveMinimumServerVersion("7.3")) { BaseResultSet acRset = //TODO: if protocol V3 we can set the client encoding in startup execSQL("set client_encoding = 'UNICODE'"); //set encoding to be unicode encoding = Encoding.getEncoding("UNICODE", null); } // Initialise object handling initObjectTypes(); // Mark the connection as ok, and cleanup PG_STATUS = CONNECTION_OK; } | 49868 /local/tlutelli/issta_data/temp/all_java4context/java/2006_temp/2006/49868/1b1d02edf788603f233f2180ff364df2f0073f0e/AbstractJdbc1Connection.java/buggy/org/postgresql/jdbc1/AbstractJdbc1Connection.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
24982,
58,
23,
12,
780,
293,
67,
2564,
16,
509,
293,
67,
655,
16,
6183,
293,
67,
1376,
16,
514,
293,
67,
6231,
16,
514,
293,
67,
718,
16,
9396,
293,
67,
72,
16,
51... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
1152,
918,
24982,
58,
23,
12,
780,
293,
67,
2564,
16,
509,
293,
67,
655,
16,
6183,
293,
67,
1376,
16,
514,
293,
67,
6231,
16,
514,
293,
67,
718,
16,
9396,
293,
67,
72,
16,
51... |
if (((index == 0) || !isWord(input[index-1])) ^ ((index < input.length) && isWord(input[index]))) ; else return -1; | if (index == 0 || !isWord(input[index-1])) { if (index < input.length && isWord(input[index])) return -1; } else { if (index >= input.length) return state.noMoreInput(); if (!isWord(input[index])) return -1; } | int matchRENodes(MatchState state, RENode ren, RENode stop, int index) { int num; char[] input = state.input; while ((ren != stop) && (ren != null)) { switch (ren.op) { case REOP_EMPTY: break; case REOP_ALT: { if (ren.next.op != REOP_ALT) { ren = (RENode)ren.kid; continue; } else { num = state.parenCount; int kidMatch = matchRENodes(state, (RENode)ren.kid, stop, index); if (kidMatch != -1) return kidMatch; for (int i = num; i < state.parenCount; i++) state.parens[i].length = 0; state.parenCount = num; } } break; case REOP_QUANT: { int lastKid = -1; for (num = 0; num < ren.min; num++) { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) return -1; else { lastKid = index; index = kidMatch; } } if (num == ren.max) // Have matched the exact count required, // need to match the rest of the regexp. break; if ((ren.flags & RENode.MINIMAL) == 0) { int kidMatch = matchGreedyKid(state, ren, stop, num, index, lastKid); if (kidMatch != -1) index = kidMatch; } else { index = matchNonGreedyKid(state, ren, num, ren.max, index); if (index == -1) return -1; } } break; case REOP_PLUS: { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) return -1; if ((ren.flags & RENode.MINIMAL) == 0) { index = matchGreedyKid(state, ren, stop, 1, kidMatch, index); if (index == -1) index = kidMatch; } else index = matchNonGreedyKid(state, ren, 1, 0, kidMatch); if (index == -1) return -1; } break; case REOP_STAR: if ((ren.flags & RENode.MINIMAL) == 0) { int kidMatch = matchGreedyKid(state, ren, stop, 0, index, -1); if (kidMatch != -1) index = kidMatch; } else { index = matchNonGreedyKid(state, ren, 0, 0, index); if (index == -1) return -1; } break; case REOP_OPT: { int saveNum = state.parenCount; if (((ren.flags & RENode.MINIMAL) != 0)) { int restMatch = matchRENodes(state, ren.next, stop, index); if (restMatch != -1) return restMatch; } int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) { state.parenCount = saveNum; break; } else { int restMatch = matchRENodes(state, ren.next, stop, kidMatch); if (restMatch == -1) { // need to undo the result of running the kid state.parenCount = saveNum; break; } else return restMatch; } } case REOP_LPARENNON: ren = (RENode)ren.kid; continue; case REOP_RPARENNON: break; case REOP_LPAREN: { num = ren.num; ren = (RENode)ren.kid; SubString parsub = state.parens[num]; if (parsub == null) { parsub = state.parens[num] = new SubString(); parsub.charArray = input; } parsub.index = index; parsub.length = 0; if (num >= state.parenCount) state.parenCount = num + 1; continue; } case REOP_RPAREN: { num = ren.num; SubString parsub = state.parens[num]; if (parsub == null) throw new RuntimeException("Paren problem"); parsub.length = index - parsub.index; break; } case REOP_ASSERT: { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch == -1) return -1; break; } case REOP_ASSERT_NOT: { int kidMatch = matchRENodes(state, (RENode)ren.kid, ren.next, index); if (kidMatch != -1) return -1; break; } case REOP_BACKREF: { num = ren.num; if (num >= state.parens.length) { Context.reportError( ScriptRuntime.getMessage( "msg.bad.backref", null)); return -1; } SubString parsub = state.parens[num]; if (parsub == null) parsub = state.parens[num] = new SubString(); int length = parsub.length; if ((input.length - index) < length) return -1; else { for (int i = 0; i < length; i++, index++) { if (!matchChar(state.flags, input[index], parsub.charArray[parsub.index + i])) return -1; } } } break; case REOP_CCLASS: if (index < input.length) { if (ren.bitmap == null) { char[] source = (ren.s != null) ? ren.s : this.source.toCharArray(); ren.buildBitmap(state, source, ((state.flags & FOLD) != 0)); } char c = input[index]; int b = (c >>> 3); if (b >= ren.bmsize) { if (ren.kid2 == -1) // a ^ class index++; else return -1; } else { int bit = c & 7; bit = 1 << bit; if ((ren.bitmap[b] & bit) != 0) index++; else return -1; } } else return -1; break; case REOP_DOT: if ((index < input.length) && (input[index] != '\n')) index++; else return -1; break; case REOP_DOTSTARMIN: { int cp2; for (cp2 = index; cp2 < input.length; cp2++) { int cp3 = matchRENodes(state, ren.next, stop, cp2); if (cp3 != -1) return cp3; if (input[cp2] == '\n') return -1; } return -1; } case REOP_DOTSTAR: { int cp2; for (cp2 = index; cp2 < input.length; cp2++) if (input[cp2] == '\n') break; while (cp2 >= index) { int cp3 = matchRENodes(state, ren.next, stop, cp2); if (cp3 != -1) { index = cp2; break; } cp2--; } break; } case REOP_WBDRY: if (((index == 0) || !isWord(input[index-1])) ^ ((index >= input.length) || !isWord(input[index]))) ; // leave index else return -1; break; case REOP_WNONBDRY: if (((index == 0) || !isWord(input[index-1])) ^ ((index < input.length) && isWord(input[index]))) ; // leave index else return -1; break; case REOP_EOLONLY: case REOP_EOL: { if (index == input.length) ; // leave index; else { Context cx = Context.getCurrentContext(); RegExpImpl reImpl = getImpl(cx); if ((reImpl.multiline) || ((state.flags & MULTILINE) != 0)) if (input[index] == '\n') ;// leave index else return -1; else return -1; } } break; case REOP_BOL: { Context cx = Context.getCurrentContext(); RegExpImpl reImpl = getImpl(cx); if (index != 0) { if ((index < input.length) && (reImpl.multiline || ((state.flags & MULTILINE) != 0))) { if (input[index - 1] == '\n') { break; } } return -1; } // leave index } break; case REOP_DIGIT: if ((index < input.length) && isDigit(input[index])) index++; else return -1; break; case REOP_NONDIGIT: if ((index < input.length) && !isDigit(input[index])) index++; else return -1; break; case REOP_ALNUM: if ((index < input.length) && isWord(input[index])) index++; else return -1; break; case REOP_NONALNUM: if ((index < input.length) && !isWord(input[index])) index++; else return -1; break; case REOP_SPACE: if ((index < input.length) && (TokenStream.isJSSpace(input[index]) || TokenStream.isJSLineTerminator(input[index]))) index++; else return -1; break; case REOP_NONSPACE: if ((index < input.length) && !(TokenStream.isJSSpace(input[index]) || TokenStream.isJSLineTerminator(input[index]))) index++; else return -1; break; case REOP_FLAT1: if ((index < input.length) && matchChar(state.flags, ren.chr, input[index])) index++; else return -1; break; case REOP_FLAT: { char[] source = (ren.s != null) ? ren.s : this.source.toCharArray(); int start = ((Integer)ren.kid).intValue(); int length = ren.kid2 - start; if ((input.length - index) < length) return -1; else { for (int i = 0; i < length; i++, index++) { if (!matchChar(state.flags, input[index], source[start + i])) return -1; } } } break; case REOP_JUMP: break; case REOP_END: break; default : throw new RuntimeException("Unsupported by node matcher"); } ren = ren.next; } return index; } | 54155 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/54155/4aee7d25d756bce350cfec71216aff6e8c8bbc4b/NativeRegExp.java/clean/js/rhino/org/mozilla/javascript/regexp/NativeRegExp.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
509,
845,
862,
3205,
12,
2060,
1119,
919,
16,
2438,
907,
1654,
16,
2438,
907,
2132,
16,
509,
770,
13,
288,
3639,
509,
818,
31,
3639,
1149,
8526,
810,
273,
919,
18,
2630,
31,
3639,
132... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
509,
845,
862,
3205,
12,
2060,
1119,
919,
16,
2438,
907,
1654,
16,
2438,
907,
2132,
16,
509,
770,
13,
288,
3639,
509,
818,
31,
3639,
1149,
8526,
810,
273,
919,
18,
2630,
31,
3639,
132... |
"45\n"); | "45\n\n"); | public void testHyphencharNullfont0() throws Exception { runCode(//--- input code --- "\\the\\hyphenchar\\nullfont" + "\\end ", //--- log message --- "", //--- output channel --- "45\n"); } | 9123 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/9123/e94fdc3e73f0aaad65cd9c0b55fddd6b8b7c0d24/HyphencharTest.java/clean/ExTeX/src/test/de/dante/extex/interpreter/primitives/font/HyphencharTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
17507,
13819,
3001,
2041,
5776,
20,
1435,
1216,
1185,
288,
3639,
1086,
1085,
12,
759,
6062,
810,
981,
9948,
7734,
8422,
5787,
1695,
18112,
13819,
3001,
1695,
2011,
5776,
6,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1842,
17507,
13819,
3001,
2041,
5776,
20,
1435,
1216,
1185,
288,
3639,
1086,
1085,
12,
759,
6062,
810,
981,
9948,
7734,
8422,
5787,
1695,
18112,
13819,
3001,
1695,
2011,
5776,
6,... |
if (status.getStatusCode() == null) { throw new ValidationException("No StatusCode element present"); } | validateStatusCode(status); | public void validate(Status status) throws ValidationException { // TODO separate methods if (status.getStatusCode() == null) { throw new ValidationException("No StatusCode element present"); } } | 52539 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52539/708465e95ae5aac021c2a8b0f3f358665c09ab6e/StatusSchemaValidator.java/buggy/src/org/opensaml/saml1/core/validator/StatusSchemaValidator.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1954,
12,
1482,
1267,
13,
1216,
15614,
288,
3639,
368,
2660,
9004,
2590,
3639,
309,
261,
2327,
18,
588,
14041,
1435,
422,
446,
13,
288,
5411,
604,
394,
15614,
2932,
2279,
10260... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1954,
12,
1482,
1267,
13,
1216,
15614,
288,
3639,
368,
2660,
9004,
2590,
3639,
309,
261,
2327,
18,
588,
14041,
1435,
422,
446,
13,
288,
5411,
604,
394,
15614,
2932,
2279,
10260... |
JOptionPane.showMessageDialog(new JFrame(), "unable to write file", "PSI-Tab makers: Tab Maker", JOptionPane.ERROR_MESSAGE); | xsdTree.getMessageManager().sendMessage("unable to write file", MessageManagerInt.errorMessage); | public void actionPerformed(ActionEvent e) { if (xsdTree.rootNode == null) { displayMessage("No schema loaded", "[PSI makers: flattener]"); return; } if (((XsdTreeStructImpl) xsdTree).document == null) { displayMessage("No document loaded", "[PSI makers: flattener]"); return; } TreeNode[] path = xsdTree.rootNode.getPath(); try { String defaultDirectory = Utils.lastVisitedDirectory; if (Utils.lastVisitedOutputDirectory != null) defaultDirectory = Utils.lastVisitedOutputDirectory; JFileChooser fileChooser = new JFileChooser(defaultDirectory); int returnVal = fileChooser.showSaveDialog(new JFrame()); if (returnVal != JFileChooser.APPROVE_OPTION) { return; } Utils.lastVisitedDirectory = fileChooser.getSelectedFile() .getPath(); Utils.lastVisitedOutputDirectory = fileChooser .getSelectedFile().getPath(); PrintWriter out = new PrintWriter(new BufferedWriter( new FileWriter(fileChooser.getSelectedFile()))); ((XsdTreeStructImpl) xsdTree).resetCount(); ((XsdTreeStructImpl) xsdTree).write(out); out.flush(); out.close(); } catch (IOException ex) { JOptionPane.showMessageDialog(new JFrame(), "unable to write file", "PSI-Tab makers: Tab Maker", JOptionPane.ERROR_MESSAGE); } } | 3154 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/3154/8317fd24793c994e235d930875bec53a6e8fe9fa/XsdTreePanelImpl.java/buggy/tools/xmlMakerFlattener/src/mint/filemakers/xmlFlattener/gui/XsdTreePanelImpl.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
26100,
12,
1803,
1133,
425,
13,
288,
1082,
202,
430,
261,
19144,
2471,
18,
3085,
907,
422,
446,
13,
288,
9506,
202,
5417,
1079,
2932,
2279,
1963,
4203,
3113,
5158,
52,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
26100,
12,
1803,
1133,
425,
13,
288,
1082,
202,
430,
261,
19144,
2471,
18,
3085,
907,
422,
446,
13,
288,
9506,
202,
5417,
1079,
2932,
2279,
1963,
4203,
3113,
5158,
52,
2... |
return null; | return this.returnValue; | public Object afterInvoke(Object object, String methodName, Object[] arguments, Object result) { return null; } | 52280 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/52280/aac2ac692981606177dc53266f1e3b37add4e357/AbstractDynamicMethodsInterceptor.java/clean/src/persistence/org/codehaus/groovy/grails/metaclass/AbstractDynamicMethodsInterceptor.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1033,
1839,
10969,
12,
921,
733,
16,
514,
4918,
16,
1082,
202,
921,
8526,
1775,
16,
1033,
563,
13,
288,
202,
202,
2463,
446,
31,
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,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
1033,
1839,
10969,
12,
921,
733,
16,
514,
4918,
16,
1082,
202,
921,
8526,
1775,
16,
1033,
563,
13,
288,
202,
202,
2463,
446,
31,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-1... |
return new Status(Status.OK, PlatformUI.PLUGIN_ID, 0, | return new Status(IStatus.OK, PlatformUI.PLUGIN_ID, 0, | private IStatus ok() { return new Status(Status.OK, PlatformUI.PLUGIN_ID, 0, ResourceNavigatorMessages.getString("DropAdapter.ok"), null); //$NON-NLS-1$ } | 57470 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/57470/946b98b8241d673f333401b6ab410949adc100b0/NavigatorDropAdapter.java/clean/bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/navigator/NavigatorDropAdapter.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
467,
1482,
1529,
1435,
288,
3639,
327,
394,
2685,
12,
45,
1482,
18,
3141,
16,
11810,
5370,
18,
19415,
67,
734,
16,
374,
16,
7734,
2591,
22817,
5058,
18,
588,
780,
2932,
7544,
4216... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
3238,
467,
1482,
1529,
1435,
288,
3639,
327,
394,
2685,
12,
45,
1482,
18,
3141,
16,
11810,
5370,
18,
19415,
67,
734,
16,
374,
16,
7734,
2591,
22817,
5058,
18,
588,
780,
2932,
7544,
4216... |
return (Function)value; | return (Callable)value; | public static Function getPropFunctionAndThis(Object obj, String property, Context cx) { Scriptable thisObj = toObjectOrNull(cx, obj); if (thisObj == null) { throw undefCallError(obj, property); } Object value; for (;;) { // Ignore XML lookup as requred by ECMA 357, 11.2.2.1 value = ScriptableObject.getProperty(thisObj, property); if (value != Scriptable.NOT_FOUND) { break; } if (!(thisObj instanceof XMLObject)) { break; } XMLObject xmlObject = (XMLObject)thisObj; Scriptable extra = xmlObject.getExtraMethodSource(cx); if (extra == null) { break; } thisObj = extra; } if (!(value instanceof Function)) { throw notFunctionError(value, property); } storeScriptable(cx, thisObj); return (Function)value; } | 12564 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12564/8f901d363ed2edf31a1885784e6ea84dee079051/ScriptRuntime.java/clean/src/org/mozilla/javascript/ScriptRuntime.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
760,
4284,
22079,
2083,
1876,
2503,
12,
921,
1081,
16,
4766,
5375,
514,
1272,
16,
4766,
5375,
1772,
9494,
13,
565,
288,
3639,
22780,
15261,
273,
24216,
18936,
12,
71,
92,
16,
1081,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4284,
22079,
2083,
1876,
2503,
12,
921,
1081,
16,
4766,
5375,
514,
1272,
16,
4766,
5375,
1772,
9494,
13,
565,
288,
3639,
22780,
15261,
273,
24216,
18936,
12,
71,
92,
16,
1081,
... |
/* this ensures that the first line is always visible */ boolean seenVisibleLine = false; | if(foldLevel == 0) { newVirtualLineCount = lineCount; } else { foldLevel = (foldLevel - 1) * buffer.getIndentSize() + 1; | public void expandFolds(int foldLevel) { int newVirtualLineCount = 0; foldLevel = (foldLevel - 1) * buffer.getIndentSize() + 1; /* this ensures that the first line is always visible */ boolean seenVisibleLine = false; for(int i = 0; i < getLineCount(); i++) { if(!seenVisibleLine || buffer.getFoldLevel(i) < foldLevel) { seenVisibleLine = true; // Since only called on load, it already has // the VISIBLE_MASK set //lineInfo[i] |= VISIBLE_MASK; newVirtualLineCount++; } else lineInfo[i] &= ~VISIBLE_MASK; } for(int i = 0; i < virtualLineCounts.length; i++) { virtualLineCounts[i] = newVirtualLineCount; } } //}}} | 8690 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8690/f5d071496833310aacbb2f71367834745f108a50/OffsetManager.java/clean/org/gjt/sp/jedit/buffer/OffsetManager.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
225,
202,
482,
918,
4542,
15592,
87,
12,
474,
11590,
2355,
13,
202,
95,
202,
202,
474,
394,
6466,
1670,
1380,
273,
374,
31,
202,
202,
16007,
2355,
273,
261,
16007,
2355,
300,
404,
13,
380,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4542,
15592,
87,
12,
474,
11590,
2355,
13,
202,
95,
202,
202,
474,
394,
6466,
1670,
1380,
273,
374,
31,
202,
202,
16007,
2355,
273,
261,
16007,
2355,
300,
404,
13,
380,
... |
static JavaMembers lookupClass(Scriptable scope, Class dynamicType, Class staticType) { Hashtable ct = classTable; // use local reference to avoid synchronize JavaMembers members = (JavaMembers) ct.get(dynamicType); if (members != null) return members; if (staticType == dynamicType) { staticType = null; } Class cl = dynamicType; if (!Modifier.isPublic(dynamicType.getModifiers())) { if (staticType == null || !Modifier.isPublic(staticType.getModifiers())) { cl = getPublicSuperclass(dynamicType); if (cl == null) { // Can happen if dynamicType is interface cl = dynamicType; } } else if (staticType.isInterface()) { // If the static type is an interface, use it cl = staticType; } else { // We can use the static type, and that is OK, but we'll trace // back the java class chain here to look for public superclass // comming before staticType cl = getPublicSuperclass(dynamicType); if (cl == null) { // Can happen if dynamicType is interface cl = dynamicType; } } } for (;;) { try { members = new JavaMembers(scope, cl); break; } catch (SecurityException e) { // Reflection may fail for objects that are in a restricted // access package (e.g. sun.*). If we get a security // exception, try again with the static type if it is interface. // Otherwise, try public superclass if (staticType != null && staticType.isInterface()) { cl = staticType; staticType = null; // try staticType only once continue; } Class parent = getPublicSuperclass(cl); if (parent == null) { if (cl.isInterface()) { // last resort parent = ScriptRuntime.ObjectClass; } else { throw e; } } cl = parent; } } if (Context.isCachingEnabled) ct.put(cl, members); return members; } | 12564 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/12564/6da65fc8773f2a78c6e00e835b26685f80c075b3/JavaMembers.java/buggy/src/org/mozilla/javascript/JavaMembers.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
760,
5110,
6918,
3689,
797,
12,
3651,
429,
2146,
16,
1659,
5976,
559,
16,
4766,
282,
1659,
760,
559,
13,
565,
288,
3639,
18559,
5691,
273,
667,
1388,
31,
225,
368,
999,
1191,
2114,
358,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5110,
6918,
3689,
797,
12,
3651,
429,
2146,
16,
1659,
5976,
559,
16,
4766,
282,
1659,
760,
559,
13,
565,
288,
3639,
18559,
5691,
273,
667,
1388,
31,
225,
368,
999,
1191,
2114,
358,... | ||
if (!isGuiActive()) { throw new AWTError("AWT is currently not available"); } if (target instanceof DesktopFrame) { setTop(target); log.debug("createFrame:desktopFramePeer(" + target + ")"); return new DesktopFramePeer(this, target); } else { if (!isGuiActive()) { throw new AWTError("Gui is not active"); } log.debug("createFrame:normal(" + target + ")"); return new SwingFramePeer(this, desktopFrame.getDesktop(), target); } } | if (!isGuiActive()) { throw new AWTError("AWT is currently not available"); } if (target instanceof DesktopFrame) { setTop(target); log.debug("createFrame:desktopFramePeer(" + target + ")"); return new DesktopFramePeer(this, target); } else { if (!isGuiActive()) { throw new AWTError("Gui is not active"); } log.debug("createFrame:normal(" + target + ")"); return new SwingFramePeer(this, desktopFrame.getDesktop(), target); } } | protected FramePeer createFrame(Frame target) { if (!isGuiActive()) { throw new AWTError("AWT is currently not available"); } if (target instanceof DesktopFrame) { setTop(target); log.debug("createFrame:desktopFramePeer(" + target + ")"); // Only desktop is real frame return new DesktopFramePeer(this, target); } else { if (!isGuiActive()) { throw new AWTError("Gui is not active"); } log.debug("createFrame:normal(" + target + ")"); // Other frames are emulated return new SwingFramePeer(this, desktopFrame.getDesktop(), target); } } | 50763 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/50763/3fecc4797b433a10203c51309b9d8626f7783895/SwingToolkit.java/clean/gui/src/awt/org/jnode/awt/swingpeers/SwingToolkit.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
8058,
6813,
752,
3219,
12,
3219,
1018,
13,
288,
3639,
309,
16051,
291,
18070,
3896,
10756,
288,
5411,
604,
394,
432,
8588,
668,
2932,
37,
8588,
353,
4551,
486,
2319,
8863,
3639,
289... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
4750,
8058,
6813,
752,
3219,
12,
3219,
1018,
13,
288,
3639,
309,
16051,
291,
18070,
3896,
10756,
288,
5411,
604,
394,
432,
8588,
668,
2932,
37,
8588,
353,
4551,
486,
2319,
8863,
3639,
289... |
if (model != null) { | if (model != null && hierarchyObject == null) { | public void execute() { if (model != null) { ImageDisplay selectedDisplay = model.getBrowser(). getSelectedDisplay(); hierarchyObject = (DataObject) selectedDisplay.getHierarchyObject(); } if (hierarchyObject == null) return; //post a show properties event. model.moveToBack(); //move the window to the back. EventBus eventBus = HiViewerAgent.getRegistry().getEventBus(); eventBus.post(new ShowProperties(hierarchyObject, ShowProperties.EDIT)); } | 13273 /local/tlutelli/issta_data/temp/all_java1context/java/2006_temp/2006/13273/03010c58165e57243d5a9590a791904493dfeec3/PropertiesCmd.java/buggy/SRC/org/openmicroscopy/shoola/agents/hiviewer/cmd/PropertiesCmd.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1836,
1435,
565,
288,
3639,
309,
261,
2284,
480,
446,
597,
9360,
921,
422,
446,
13,
288,
5411,
3421,
4236,
3170,
4236,
273,
938,
18,
588,
9132,
7675,
4766,
10792,
16625,
4236,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
1836,
1435,
565,
288,
3639,
309,
261,
2284,
480,
446,
597,
9360,
921,
422,
446,
13,
288,
5411,
3421,
4236,
3170,
4236,
273,
938,
18,
588,
9132,
7675,
4766,
10792,
16625,
4236,
... |
ok = ok || (javaVersion.startsWith("1.2") && (fmtDstOffset != null) && fmtDstOffset.equals("")); | ok = ok || ((javaVersion.startsWith("1.2") || javaVersion.startsWith("1.3.0")) && (fmtDstOffset != null) && fmtDstOffset.equals("")); | public void TestWallyWedel() { /* * Instantiate a TimeZone so we can get the ids. */ //TimeZone tz = new SimpleTimeZone(7, ""); //The variable is never used /* * Computational variables. */ int offset, hours, minutes; /* * Instantiate a SimpleDateFormat set up to produce a full time zone name. */ SimpleDateFormat sdf = new SimpleDateFormat("zzzz"); /* * A String array for the time zone ids. */ final String[] ids = TimeZone.getAvailableIDs(); int ids_length = ids.length; //when fixed the bug should comment it out /* * How many ids do we have? */ logln("Time Zone IDs size:" + ids_length); /* * Column headings (sort of) */ logln("Ordinal ID offset(h:m) name"); /* * Loop through the tzs. */ Date today = new Date(); Calendar cal = Calendar.getInstance(); for (int i = 0; i < ids_length; i++) { logln(i + " " + ids[i]); TimeZone ttz = TimeZone.getTimeZone(ids[i]); // offset = ttz.getRawOffset(); cal.setTimeZone(ttz); cal.setTime(today); offset = cal.get(Calendar.ZONE_OFFSET) + cal.get(Calendar.DST_OFFSET); // logln(i + " " + ids[i] + " offset " + offset); String sign = "+"; if (offset < 0) { sign = "-"; offset = -offset; } hours = offset / 3600000; minutes = (offset % 3600000) / 60000; String dstOffset = sign + (hours < 10 ? "0" : "") + hours + ":" + (minutes < 10 ? "0" : "") + minutes; /* * Instantiate a date so we can display the time zone name. */ sdf.setTimeZone(ttz); /* * Format the output. */ StringBuffer fmtOffset = new StringBuffer(""); FieldPosition pos = new FieldPosition(0); try { fmtOffset = sdf.format(today, fmtOffset, pos); } catch (Exception e) { logln("Exception:" + e); continue; } // UnicodeString fmtOffset = tzS.toString(); String fmtDstOffset = null; if (fmtOffset.toString().startsWith("GMT")) { //fmtDstOffset = fmtOffset.substring(3); fmtDstOffset = fmtOffset.substring(3, fmtOffset.length()); } /* * Show our result. */ boolean ok = fmtDstOffset == null || fmtDstOffset.equals(dstOffset); //fix the jdk resources differences between jdk 1.2 and jdk 1.3 String javaVersion = System.getProperty("java.version"); ok = ok || (javaVersion.startsWith("1.2") && (fmtDstOffset != null) && fmtDstOffset.equals("")); if (ok) { logln(i + " " + ids[i] + " " + dstOffset + " " + fmtOffset + (fmtDstOffset != null ? " ok" : " ?")); } else { errln(i + " " + ids[i] + " " + dstOffset + " " + fmtOffset + " *** FAIL ***"); } } } | 5620 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/5620/ba037164ec96bd72824b00088a4bba2c09ed43f8/DateFormatTest.java/buggy/icu4j/src/com/ibm/icu/test/format/DateFormatTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
918,
7766,
59,
1230,
59,
329,
292,
1435,
288,
3639,
1748,
540,
380,
26492,
279,
16491,
1427,
732,
848,
336,
326,
3258,
18,
540,
1195,
3639,
368,
16760,
6016,
273,
394,
4477,
16760,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
7766,
59,
1230,
59,
329,
292,
1435,
288,
3639,
1748,
540,
380,
26492,
279,
16491,
1427,
732,
848,
336,
326,
3258,
18,
540,
1195,
3639,
368,
16760,
6016,
273,
394,
4477,
16760,
... |
public void handleStale(IObservable source) { | public void handleStale(StaleEvent event) { | public void handleStale(IObservable source) { count++; this.source = source; } | 55805 /local/tlutelli/issta_data/temp/all_java5context/java/2006_temp/2006/55805/6aecdb31231a8602dbf72944625703c440949c78/UnmodifiableObservableListTest.java/buggy/tests/org.eclipse.jface.tests.databinding/src/org/eclipse/jface/tests/internal/databinding/internal/observable/UnmodifiableObservableListTest.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
1640,
19155,
12,
4294,
3745,
1084,
13,
288,
1082,
202,
1883,
9904,
31,
1082,
202,
2211,
18,
3168,
273,
1084,
31,
202,
202,
97,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
3196,
202,
482,
918,
1640,
19155,
12,
4294,
3745,
1084,
13,
288,
1082,
202,
1883,
9904,
31,
1082,
202,
2211,
18,
3168,
273,
1084,
31,
202,
202,
97,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
} catch ( RuntimeException e ) { log.error("parseDoc(Vector, String, String): RuntimeException", e ); throw e ; } catch ( IOException e ) { log.error("parseDoc(Vector, String, String): IOException", e ); return "" ; | } catch ( RuntimeException ex ) { log.error("parseDoc(String,Vector): RuntimeException", ex ); throw ex ; | public String parseDoc(java.util.Vector variables, String admin_template_name, String lang_prefix) { try { String htmlStr = fileCache.getCachedFileString(new File(m_TemplateHome,lang_prefix+"/admin/"+admin_template_name)) ; if (variables == null) { return htmlStr ; } String[] foo = new String[variables.size()] ; return imcode.util.Parser.parseDoc(htmlStr,(String[])variables.toArray(foo)) ; } catch ( RuntimeException e ) { log.error("parseDoc(Vector, String, String): RuntimeException", e ); throw e ; } catch ( IOException e ) { log.error("parseDoc(Vector, String, String): IOException", e ); return "" ; } } | 8781 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/8781/02e99efc247ed8f17d58173f1c97fb12dd91298c/IMCService.java/buggy/server/src/imcode/server/IMCService.java | [
1,
8585,
326,
22398,
316,
326,
981,
30,
377,
1071,
514,
1109,
1759,
12,
6290,
18,
1367,
18,
5018,
3152,
16,
514,
3981,
67,
3202,
67,
529,
16,
514,
3303,
67,
3239,
13,
288,
202,
698,
288,
202,
565,
514,
1729,
1585,
273,
585,
1649... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1109,
1759,
12,
6290,
18,
1367,
18,
5018,
3152,
16,
514,
3981,
67,
3202,
67,
529,
16,
514,
3303,
67,
3239,
13,
288,
202,
698,
288,
202,
565,
514,
1729,
1585,
273,
585,
1649... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.