nus-yam/ex-repair huggingface dataset:
Program: 36002
Project: 36002
Buggy source:
/** 
 * Tells listeners that the selection model of the TableColumnModel changed.
 */
public void columnSelectionChanged(ListSelectionEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that the selection model of the TableColumnModel changed.
 * @param e a {@code ListSelectionEvent}
 */
public void columnSelectionChanged(ListSelectionEvent e);
Program: 36003
Project: 36003
Buggy source:
/** 
 * Tells listeners that a column was removed from the model. 
 */
public void columnRemoved(TableColumnModelEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that a column was removed from the model.
 * @param e a {@code TableColumnModelEvent}
 */
public void columnRemoved(TableColumnModelEvent e);
Program: 36004
Project: 36004
Buggy source:
/** 
 * Tells listeners that a column was moved due to a margin change. 
 */
public void columnMarginChanged(ChangeEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that a column was moved due to a margin change.
 * @param e a {@code ChangeEvent}
 */
public void columnMarginChanged(ChangeEvent e);
Program: 36005
Project: 36005
Buggy source:
/** 
 * Tells listeners that a column was added to the model. 
 */
public void columnAdded(TableColumnModelEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that a column was added to the model.
 * @param e a {@code TableColumnModelEvent}
 */
public void columnAdded(TableColumnModelEvent e);
Program: 36006
Project: 36006
Buggy source:
/** 
 * Supports reporting bound property changes.  This method can be called when a bound property has changed and it will send the appropriate <code>PropertyChangeEvent</code> to any registered <code>PropertyChangeListeners</code>.
 */
protected void firePropertyChange(String propertyName,Object oldValue,Object newValue){
  if (changeSupport == null || (oldValue != null && newValue != null && oldValue.equals(newValue))) {
    return;
  }
  changeSupport.firePropertyChange(propertyName,oldValue,newValue);
}

Fixed version (ground truth):
/** 
 * Supports reporting bound property changes.  This method can be called when a bound property has changed and it will send the appropriate <code>PropertyChangeEvent</code> to any registered <code>PropertyChangeListeners</code>.
 * @param propertyName  the name of the property that has changed
 * @param oldValue  the old value of the property
 * @param newValue  the new value of the property
 */
protected void firePropertyChange(String propertyName,Object oldValue,Object newValue){
  if (changeSupport == null || (oldValue != null && newValue != null && oldValue.equals(newValue))) {
    return;
  }
  changeSupport.firePropertyChange(propertyName,oldValue,newValue);
}
Program: 36007
Project: 36007
Buggy source:
/** 
 * Calls this.paintComponent() with the rectangles x,y,width,height fields.
 */
public void paintComponent(Graphics g,Component c,Container p,Rectangle r){
  paintComponent(g,c,p,r.x,r.y,r.width,r.height);
}

Fixed version (ground truth):
/** 
 * Calls this.paintComponent() with the rectangles x,y,width,height fields.
 * @param g  the {@code Graphics} object to draw on
 * @param c  the {@code Component} to draw
 * @param p  the {@code Container} component actually drawn on
 * @param r  the {@code Rectangle} to draw in
 */
public void paintComponent(Graphics g,Component c,Container p,Rectangle r){
  paintComponent(g,c,p,r.x,r.y,r.width,r.height);
}
Program: 36008
Project: 36008
Buggy source:
/** 
 * Sets the number of times that drawing operations will flash.
 */
public static void setFlashCount(int flashCount){
  info().flashCount=flashCount;
}

Fixed version (ground truth):
/** 
 * Sets the number of times that drawing operations will flash.
 * @param flashCount number of times that drawing operations will flash
 */
public static void setFlashCount(int flashCount){
  info().flashCount=flashCount;
}
Program: 36009
Project: 36009
Buggy source:
/** 
 * Returns the stream to which the DebugGraphics logs drawing operations.
 * @see #setLogStream
 */
public static java.io.PrintStream logStream(){
  return info().stream;
}

Fixed version (ground truth):
/** 
 * Returns the stream to which the DebugGraphics logs drawing operations.
 * @return the stream to which the DebugGraphics logs drawing operations
 * @see #setLogStream
 */
public static java.io.PrintStream logStream(){
  return info().stream;
}
Program: 36010
Project: 36010
Buggy source:
/** 
 * Sets the stream to which the DebugGraphics logs drawing operations.
 */
public static void setLogStream(java.io.PrintStream stream){
  info().stream=stream;
}

Fixed version (ground truth):
/** 
 * Sets the stream to which the DebugGraphics logs drawing operations.
 * @param stream the stream to which the DebugGraphics logs drawing operations
 */
public static void setLogStream(java.io.PrintStream stream){
  info().stream=stream;
}
Program: 36011
Project: 36011
Buggy source:
/** 
 * Returns the time delay of drawing operation flashing.
 * @see #setFlashTime
 */
public static int flashTime(){
  return info().flashTime;
}

Fixed version (ground truth):
/** 
 * Returns the time delay of drawing operation flashing.
 * @return the time delay of drawing operation flashing
 * @see #setFlashTime
 */
public static int flashTime(){
  return info().flashTime;
}
Program: 36012
Project: 36012
Buggy source:
/** 
 * Returns the number of times that drawing operations will flash.
 * @see #setFlashCount
 */
public static int flashCount(){
  return info().flashCount;
}

Fixed version (ground truth):
/** 
 * Returns the number of times that drawing operations will flash.
 * @return the number of times that drawing operations will flash
 * @see #setFlashCount
 */
public static int flashCount(){
  return info().flashCount;
}
Program: 36013
Project: 36013
Buggy source:
/** 
 * Sets the time delay of drawing operation flashing.
 */
public static void setFlashTime(int flashTime){
  info().flashTime=flashTime;
}

Fixed version (ground truth):
/** 
 * Sets the time delay of drawing operation flashing.
 * @param flashTime the time delay of drawing operation flashing
 */
public static void setFlashTime(int flashTime){
  info().flashTime=flashTime;
}
Program: 36014
Project: 36014
Buggy source:
/** 
 * Returns the Color used to flash drawing operations.
 * @see #setFlashColor
 */
public static Color flashColor(){
  return info().flashColor;
}

Fixed version (ground truth):
/** 
 * Returns the Color used to flash drawing operations.
 * @return the Color used to flash drawing operations
 * @see #setFlashColor
 */
public static Color flashColor(){
  return info().flashColor;
}
Program: 36015
Project: 36015
Buggy source:
/** 
 * Sets the Color used to flash drawing operations.
 */
public static void setFlashColor(Color flashColor){
  info().flashColor=flashColor;
}

Fixed version (ground truth):
/** 
 * Sets the Color used to flash drawing operations.
 * @param flashColor the Color used to flash drawing operations
 */
public static void setFlashColor(Color flashColor){
  info().flashColor=flashColor;
}
Program: 36016
Project: 36016
Buggy source:
/** 
 * Returns an array of all the objects currently registered as <code><em>Foo</em>Listener</code>s upon this model. <code><em>Foo</em>Listener</code>s are registered using the <code>add<em>Foo</em>Listener</code> method. <p> You can specify the <code>listenerType</code> argument with a class literal, such as <code><em>Foo</em>Listener.class</code>. For example, you can query a <code>DefaultBoundedRangeModel</code> instance <code>m</code> for its change listeners with the following code: <pre>ChangeListener[] cls = (ChangeListener[])(m.getListeners(ChangeListener.class));</pre> If no such listeners exist, this method returns an empty array.
 * @param listenerType  the type of listeners requested;this parameter should specify an interface that descends from <code>java.util.EventListener</code>
 * @return an array of all objects registered as<code><em>Foo</em>Listener</code>s on this model, or an empty array if no such listeners have been added
 * @exception ClassCastException if <code>listenerType</code> doesn'tspecify a class or interface that implements <code>java.util.EventListener</code>
 * @see #getChangeListeners
 * @since 1.3
 */
public <T extends EventListener>T[] getListeners(Class<T> listenerType){
  return listenerList.getListeners(listenerType);
}

Fixed version (ground truth):
/** 
 * Returns an array of all the objects currently registered as <code><em>Foo</em>Listener</code>s upon this model. <code><em>Foo</em>Listener</code>s are registered using the <code>add<em>Foo</em>Listener</code> method. <p> You can specify the <code>listenerType</code> argument with a class literal, such as <code><em>Foo</em>Listener.class</code>. For example, you can query a <code>DefaultBoundedRangeModel</code> instance <code>m</code> for its change listeners with the following code: <pre>ChangeListener[] cls = (ChangeListener[])(m.getListeners(ChangeListener.class));</pre> If no such listeners exist, this method returns an empty array.
 * @param < T > the type of {@code EventListener} class being requested
 * @param listenerType  the type of listeners requested;this parameter should specify an interface that descends from <code>java.util.EventListener</code>
 * @return an array of all objects registered as<code><em>Foo</em>Listener</code>s on this model, or an empty array if no such listeners have been added
 * @exception ClassCastException if <code>listenerType</code> doesn'tspecify a class or interface that implements <code>java.util.EventListener</code>
 * @see #getChangeListeners
 * @since 1.3
 */
public <T extends EventListener>T[] getListeners(Class<T> listenerType){
  return listenerList.getListeners(listenerType);
}
Program: 36017
Project: 36017
Buggy source:
/** 
 * Initializes value, extent, minimum and maximum. Adjusting is false. Throws an <code>IllegalArgumentException</code> if the following constraints aren't satisfied: <pre> min &lt;= value &lt;= value+extent &lt;= max </pre>
 */
public DefaultBoundedRangeModel(int value,int extent,int min,int max){
  if ((max >= min) && (value >= min) && ((value + extent) >= value)&& ((value + extent) <= max)) {
    this.value=value;
    this.extent=extent;
    this.min=min;
    this.max=max;
  }
 else {
    throw new IllegalArgumentException("String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * Initializes value, extent, minimum and maximum. Adjusting is false. Throws an <code>IllegalArgumentException</code> if the following constraints aren't satisfied: <pre> min &lt;= value &lt;= value+extent &lt;= max </pre>
 * @param value  an int giving the current value
 * @param extent the length of the inner range that begins at the model's value
 * @param min    an int giving the minimum value
 * @param max    an int giving the maximum value
 */
public DefaultBoundedRangeModel(int value,int extent,int min,int max){
  if ((max >= min) && (value >= min) && ((value + extent) >= value)&& ((value + extent) <= max)) {
    this.value=value;
    this.extent=extent;
    this.min=min;
    this.max=max;
  }
 else {
    throw new IllegalArgumentException("String_Node_Str");
  }
}
Program: 36018
Project: 36018
Buggy source:
/** 
 * Normally this method will not be called. If it is, it try to determine the appropriate parent from the desktopIcon of the frame. Will remove the desktopIcon from its parent if it successfully adds the frame.
 */
public void openFrame(JInternalFrame f){
  if (f.getDesktopIcon().getParent() != null) {
    f.getDesktopIcon().getParent().add(f);
    removeIconFor(f);
  }
}

Fixed version (ground truth):
/** 
 * Normally this method will not be called. If it is, it tries to determine the appropriate parent from the desktopIcon of the frame. Will remove the desktopIcon from its parent if it successfully adds the frame.
 */
public void openFrame(JInternalFrame f){
  if (f.getDesktopIcon().getParent() != null) {
    f.getDesktopIcon().getParent().add(f);
    removeIconFor(f);
  }
}
Program: 36019
Project: 36019
Buggy source:
/** 
 * Returns an array of all the objects currently registered as <code><em>Foo</em>Listener</code>s upon this model. <code><em>Foo</em>Listener</code>s are registered using the <code>add<em>Foo</em>Listener</code> method. <p> You can specify the <code>listenerType</code> argument with a class literal, such as <code><em>Foo</em>Listener.class</code>. For example, you can query a <code>DefaultSingleSelectionModel</code> instance <code>m</code> for its change listeners with the following code: <pre>ChangeListener[] cls = (ChangeListener[])(m.getListeners(ChangeListener.class));</pre> If no such listeners exist, this method returns an empty array.
 * @param listenerType  the type of listeners requested;this parameter should specify an interface that descends from <code>java.util.EventListener</code>
 * @return an array of all objects registered as<code><em>Foo</em>Listener</code>s on this model, or an empty array if no such listeners have been added
 * @exception ClassCastException if <code>listenerType</code> doesn'tspecify a class or interface that implements <code>java.util.EventListener</code>
 * @see #getChangeListeners
 * @since 1.3
 */
public <T extends EventListener>T[] getListeners(Class<T> listenerType){
  return listenerList.getListeners(listenerType);
}

Fixed version (ground truth):
/** 
 * Returns an array of all the objects currently registered as <code><em>Foo</em>Listener</code>s upon this model. <code><em>Foo</em>Listener</code>s are registered using the <code>add<em>Foo</em>Listener</code> method. <p> You can specify the <code>listenerType</code> argument with a class literal, such as <code><em>Foo</em>Listener.class</code>. For example, you can query a <code>DefaultSingleSelectionModel</code> instance <code>m</code> for its change listeners with the following code: <pre>ChangeListener[] cls = (ChangeListener[])(m.getListeners(ChangeListener.class));</pre> If no such listeners exist, this method returns an empty array.
 * @param < T >  the type of {@code EventListener} class being requested
 * @param listenerType  the type of listeners requested;this parameter should specify an interface that descends from <code>java.util.EventListener</code>
 * @return an array of all objects registered as<code><em>Foo</em>Listener</code>s on this model, or an empty array if no such listeners have been added
 * @exception ClassCastException if <code>listenerType</code> doesn'tspecify a class or interface that implements <code>java.util.EventListener</code>
 * @see #getChangeListeners
 * @since 1.3
 */
public <T extends EventListener>T[] getListeners(Class<T> listenerType){
  return listenerList.getListeners(listenerType);
}
Program: 36020
Project: 36020
Buggy source:
/** 
 * Generally, remove this frame from it's parent and add an iconic representation. 
 */
void iconifyFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * Generally, remove this frame from its parent and add an iconic representation.
 * @param f  the {@code JInternalFrame} to be iconified
 */
void iconifyFrame(JInternalFrame f);
Program: 36021
Project: 36021
Buggy source:
/** 
 * Generally, this indicates that the frame should be restored to it's size and position prior to a maximizeFrame() call.
 */
void minimizeFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * Generally, this indicates that the frame should be restored to its size and position prior to a maximizeFrame() call.
 * @param f  the {@code JInternalFrame} to be restored
 */
void minimizeFrame(JInternalFrame f);
Program: 36022
Project: 36022
Buggy source:
/** 
 * Generally, this call should remove the frame from it's parent. 
 */
void closeFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * Generally, this call should remove the frame from its parent.
 * @param f  the {@code JInternalFrame} to be removed
 */
void closeFrame(JInternalFrame f);
Program: 36023
Project: 36023
Buggy source:
/** 
 * Generally, remove any iconic representation that is present and restore the frame to it's original size and location.
 */
void deiconifyFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * Generally, remove any iconic representation that is present and restore the frame to it's original size and location.
 * @param f  the {@code JInternalFrame} to be de-iconified
 */
void deiconifyFrame(JInternalFrame f);
Program: 36024
Project: 36024
Buggy source:
/** 
 * Generally, indicate that this frame has focus. This is usually called after the JInternalFrame's IS_SELECTED_PROPERTY has been set to true.
 */
void activateFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * Generally, indicate that this frame has focus. This is usually called after the JInternalFrame's IS_SELECTED_PROPERTY has been set to true.
 * @param f  the {@code JInternalFrame} to be activated
 */
void activateFrame(JInternalFrame f);
Program: 36025
Project: 36025
Buggy source:
/** 
 * This methods is normally called when the user has indicated that they will begin resizing the frame. This method should be called prior to any resizeFrame() calls to allow the DesktopManager to prepare any necessary state.  Normally <b>f</b> will be a JInternalFrame.
 */
void beginResizingFrame(JComponent f,int direction);

Fixed version (ground truth):
/** 
 * This method is normally called when the user has indicated that they will begin resizing the frame. This method should be called prior to any resizeFrame() calls to allow the DesktopManager to prepare any necessary state.  Normally <b>f</b> will be a JInternalFrame.
 * @param f  the {@code JComponent} being resized
 */
void beginResizingFrame(JComponent f,int direction);
Program: 36026
Project: 36026
Buggy source:
/** 
 * The user has moved the frame. Calls to this method will be preceded by calls to beginDraggingFrame(). Normally <b>f</b> will be a JInternalFrame.
 */
void dragFrame(JComponent f,int newX,int newY);

Fixed version (ground truth):
/** 
 * The user has moved the frame. Calls to this method will be preceded by calls to beginDraggingFrame(). Normally <b>f</b> will be a JInternalFrame.
 * @param f  the {@code JComponent} being dragged
 * @param newX  the new x-coordinate
 * @param newY  the new y-coordinate
 */
void dragFrame(JComponent f,int newX,int newY);
Program: 36027
Project: 36027
Buggy source:
/** 
 * If possible, display this frame in an appropriate location. Normally, this is not called, as the creator of the JInternalFrame will add the frame to the appropriate parent.
 */
void openFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * If possible, display this frame in an appropriate location. Normally, this is not called, as the creator of the JInternalFrame will add the frame to the appropriate parent.
 * @param f  the {@code JInternalFrame} to be displayed
 */
void openFrame(JInternalFrame f);
Program: 36028
Project: 36028
Buggy source:
/** 
 * Generally, the frame should be resized to match it's parents bounds. 
 */
void maximizeFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * Generally, the frame should be resized to match its parents bounds.
 * @param f  the {@code JInternalFrame} to be resized
 */
void maximizeFrame(JInternalFrame f);
Program: 36029
Project: 36029
Buggy source:
/** 
 * This method is normally called when the user has indicated that they will begin dragging a component around. This method should be called prior to any dragFrame() calls to allow the DesktopManager to prepare any necessary state. Normally <b>f</b> will be a JInternalFrame.
 */
void beginDraggingFrame(JComponent f);

Fixed version (ground truth):
/** 
 * This method is normally called when the user has indicated that they will begin dragging a component around. This method should be called prior to any dragFrame() calls to allow the DesktopManager to prepare any necessary state. Normally <b>f</b> will be a JInternalFrame.
 * @param f  the {@code JComponent} being dragged
 */
void beginDraggingFrame(JComponent f);
Program: 36030
Project: 36030
Buggy source:
/** 
 * Generally, indicate that this frame has lost focus. This is usually called after the JInternalFrame's IS_SELECTED_PROPERTY has been set to false.
 */
void deactivateFrame(JInternalFrame f);

Fixed version (ground truth):
/** 
 * Generally, indicate that this frame has lost focus. This is usually called after the JInternalFrame's IS_SELECTED_PROPERTY has been set to false.
 * @param f  the {@code JInternalFrame} to be deactivated
 */
void deactivateFrame(JInternalFrame f);
Program: 36031
Project: 36031
Buggy source:
/** 
 * The user has resized the component. Calls to this method will be preceded by calls to beginResizingFrame(). Normally <b>f</b> will be a JInternalFrame.
 */
void resizeFrame(JComponent f,int newX,int newY,int newWidth,int newHeight);

Fixed version (ground truth):
/** 
 * The user has resized the component. Calls to this method will be preceded by calls to beginResizingFrame(). Normally <b>f</b> will be a JInternalFrame.
 * @param f  the {@code JComponent} being resized
 * @param newX  the new x-coordinate
 * @param newY  the new y-coordinate
 * @param newWidth  the new width
 * @param newHeight  the new height
 */
void resizeFrame(JComponent f,int newX,int newY,int newWidth,int newHeight);
Program: 36032
Project: 36032
Buggy source:
/** 
 * This method signals the end of the resize session. Any state maintained by the DesktopManager can be removed here.  Normally <b>f</b> will be a JInternalFrame.
 */
void endResizingFrame(JComponent f);

Fixed version (ground truth):
/** 
 * This method signals the end of the resize session. Any state maintained by the DesktopManager can be removed here.  Normally <b>f</b> will be a JInternalFrame.
 * @param f  the {@code JComponent} being resized
 */
void endResizingFrame(JComponent f);
Program: 36033
Project: 36033
Buggy source:
/** 
 * This method signals the end of the dragging session. Any state maintained by the DesktopManager can be removed here.  Normally <b>f</b> will be a JInternalFrame.
 */
void endDraggingFrame(JComponent f);

Fixed version (ground truth):
/** 
 * This method signals the end of the dragging session. Any state maintained by the DesktopManager can be removed here.  Normally <b>f</b> will be a JInternalFrame.
 * @param f  the {@code JComponent} being dragged
 */
void endDraggingFrame(JComponent f);
Program: 36034
Project: 36034
Buggy source:
/** 
 * This is a primitive reshape method.
 */
void setBoundsForFrame(JComponent f,int newX,int newY,int newWidth,int newHeight);

Fixed version (ground truth):
/** 
 * This is a primitive reshape method.
 * @param f  the {@code JComponent} being moved or resized
 * @param newX  the new x-coordinate
 * @param newY  the new y-coordinate
 * @param newWidth  the new width
 * @param newHeight  the new height
 */
void setBoundsForFrame(JComponent f,int newX,int newY,int newWidth,int newHeight);
Program: 36035
Project: 36035
Buggy source:
/** 
 * Returns the ancestor that the event actually occurred on.
 */
public Container getAncestor(){
  return ancestor;
}

Fixed version (ground truth):
/** 
 * Returns the ancestor that the event actually occurred on.
 * @return the {@code Container} object specifying the ancestor component
 */
public Container getAncestor(){
  return ancestor;
}
Program: 36036
Project: 36036
Buggy source:
/** 
 * Returns the parent of the ancestor the event actually occurred on. This is most interesting in an ANCESTOR_REMOVED event, as the ancestor may no longer be in the component hierarchy.
 */
public Container getAncestorParent(){
  return ancestorParent;
}

Fixed version (ground truth):
/** 
 * Returns the parent of the ancestor the event actually occurred on. This is most interesting in an ANCESTOR_REMOVED event, as the ancestor may no longer be in the component hierarchy.
 * @return the {@code Container} object specifying the ancestor's parent
 */
public Container getAncestorParent(){
  return ancestorParent;
}
Program: 36037
Project: 36037
Buggy source:
/** 
 * Returns the component that the listener was added to.
 */
public JComponent getComponent(){
  return (JComponent)getSource();
}

Fixed version (ground truth):
/** 
 * Returns the component that the listener was added to.
 * @return the {@code JComponent} on which the event occurred
 */
public JComponent getComponent(){
  return (JComponent)getSource();
}
Program: 36038
Project: 36038
Buggy source:
/** 
 * Called when the source or one of its ancestors is made visible either by setVisible(true) being called or by its being added to the component hierarchy.  The method is only called if the source has actually become visible.  For this to be true all its parents must be visible and it must be in a hierarchy rooted at a Window
 */
public void ancestorAdded(AncestorEvent event);

Fixed version (ground truth):
/** 
 * Called when the source or one of its ancestors is made visible either by setVisible(true) being called or by its being added to the component hierarchy.  The method is only called if the source has actually become visible.  For this to be true all its parents must be visible and it must be in a hierarchy rooted at a Window
 * @param event an {@code AncestorEvent} signifying a change in anancestor-component's display-status
 */
public void ancestorAdded(AncestorEvent event);
Program: 36039
Project: 36039
Buggy source:
/** 
 * Called when either the source or one of its ancestors is moved.
 */
public void ancestorMoved(AncestorEvent event);

Fixed version (ground truth):
/** 
 * Called when either the source or one of its ancestors is moved.
 * @param event an {@code AncestorEvent} signifying a change in anancestor-component's display-status
 */
public void ancestorMoved(AncestorEvent event);
Program: 36040
Project: 36040
Buggy source:
/** 
 * Called when the source or one of its ancestors is made invisible either by setVisible(false) being called or by its being remove from the component hierarchy.  The method is only called if the source has actually become invisible.  For this to be true at least one of its parents must by invisible or it is not in a hierarchy rooted at a Window
 */
public void ancestorRemoved(AncestorEvent event);

Fixed version (ground truth):
/** 
 * Called when the source or one of its ancestors is made invisible either by setVisible(false) being called or by its being remove from the component hierarchy.  The method is only called if the source has actually become invisible.  For this to be true at least one of its parents must by invisible or it is not in a hierarchy rooted at a Window
 * @param event an {@code AncestorEvent} signifying a change in anancestor-component's display-status
 */
public void ancestorRemoved(AncestorEvent event);
Program: 36041
Project: 36041
Buggy source:
/** 
 * This tells the listeners the editor has ended editing 
 */
public void editingStopped(ChangeEvent e);

Fixed version (ground truth):
/** 
 * This tells the listeners the editor has ended editing
 * @param e the {@code ChangeEvent} containing the source of the event
 */
public void editingStopped(ChangeEvent e);
Program: 36042
Project: 36042
Buggy source:
/** 
 * This tells the listeners the editor has canceled editing 
 */
public void editingCanceled(ChangeEvent e);

Fixed version (ground truth):
/** 
 * This tells the listeners the editor has canceled editing
 * @param e the {@code ChangeEvent} containing the source of the event
 */
public void editingCanceled(ChangeEvent e);
Program: 36043
Project: 36043
Buggy source:
/** 
 * Return an array of all the listeners of the given type.
 * @return all of the listeners of the specified type.
 * @exception ClassCastException if the supplied classis not assignable to EventListener
 * @since 1.3
 */
public <T extends EventListener>T[] getListeners(Class<T> t){
  Object[] lList=listenerList;
  int n=getListenerCount(lList,t);
  T[] result=(T[])Array.newInstance(t,n);
  int j=0;
  for (int i=lList.length - 2; i >= 0; i-=2) {
    if (lList[i] == t) {
      result[j++]=(T)lList[i + 1];
    }
  }
  return result;
}

Fixed version (ground truth):
/** 
 * Return an array of all the listeners of the given type.
 * @param < T > the type of {@code EventListener} to search for
 * @param t the type of {@code EventListener} classes to be returned
 * @return all of the listeners of the specified type.
 * @exception ClassCastException if the supplied classis not assignable to EventListener
 * @since 1.3
 */
public <T extends EventListener>T[] getListeners(Class<T> t){
  Object[] lList=listenerList;
  int n=getListenerCount(lList,t);
  T[] result=(T[])Array.newInstance(t,n);
  int j=0;
  for (int i=lList.length - 2; i >= 0; i-=2) {
    if (lList[i] == t) {
      result[j++]=(T)lList[i + 1];
    }
  }
  return result;
}
Program: 36044
Project: 36044
Buggy source:
/** 
 * Adds the listener as a listener of the specified type.
 * @param t the type of the listener to be added
 * @param l the listener to be added
 */
public synchronized <T extends EventListener>void add(Class<T> t,T l){
  if (l == null) {
    return;
  }
  if (!t.isInstance(l)) {
    throw new IllegalArgumentException("String_Node_Str" + l + "String_Node_Str"+ t);
  }
  if (listenerList == NULL_ARRAY) {
    listenerList=new Object[]{t,l};
  }
 else {
    int i=listenerList.length;
    Object[] tmp=new Object[i + 2];
    System.arraycopy(listenerList,0,tmp,0,i);
    tmp[i]=t;
    tmp[i + 1]=l;
    listenerList=tmp;
  }
}

Fixed version (ground truth):
/** 
 * Adds the listener as a listener of the specified type.
 * @param < T > the type of {@code EventListener} to add
 * @param t the type of the {@code EventListener} class to add
 * @param l the listener to be added
 */
public synchronized <T extends EventListener>void add(Class<T> t,T l){
  if (l == null) {
    return;
  }
  if (!t.isInstance(l)) {
    throw new IllegalArgumentException("String_Node_Str" + l + "String_Node_Str"+ t);
  }
  if (listenerList == NULL_ARRAY) {
    listenerList=new Object[]{t,l};
  }
 else {
    int i=listenerList.length;
    Object[] tmp=new Object[i + 2];
    System.arraycopy(listenerList,0,tmp,0,i);
    tmp[i]=t;
    tmp[i + 1]=l;
    listenerList=tmp;
  }
}
Program: 36045
Project: 36045
Buggy source:
/** 
 * Passes back the event listener list as an array of ListenerType-listener pairs.  Note that for performance reasons, this implementation passes back the actual data structure in which the listener data is stored internally! This method is guaranteed to pass back a non-null array, so that no null-checking is required in fire methods.  A zero-length array of Object should be returned if there are currently no listeners. WARNING!!! Absolutely NO modification of the data contained in this array should be made -- if any such manipulation is necessary, it should be done on a copy of the array returned rather than the array itself.
 */
public Object[] getListenerList(){
  return listenerList;
}

Fixed version (ground truth):
/** 
 * Passes back the event listener list as an array of ListenerType-listener pairs.  Note that for performance reasons, this implementation passes back the actual data structure in which the listener data is stored internally! This method is guaranteed to pass back a non-null array, so that no null-checking is required in fire methods.  A zero-length array of Object should be returned if there are currently no listeners. WARNING!!! Absolutely NO modification of the data contained in this array should be made -- if any such manipulation is necessary, it should be done on a copy of the array returned rather than the array itself.
 * @return array of ListenerType-listener pairs
 */
public Object[] getListenerList(){
  return listenerList;
}
Program: 36046
Project: 36046
Buggy source:
/** 
 * Removes the listener as a listener of the specified type.
 * @param t the type of the listener to be removed
 * @param l the listener to be removed
 */
public synchronized <T extends EventListener>void remove(Class<T> t,T l){
  if (l == null) {
    return;
  }
  if (!t.isInstance(l)) {
    throw new IllegalArgumentException("String_Node_Str" + l + "String_Node_Str"+ t);
  }
  int index=-1;
  for (int i=listenerList.length - 2; i >= 0; i-=2) {
    if ((listenerList[i] == t) && (listenerList[i + 1].equals(l) == true)) {
      index=i;
      break;
    }
  }
  if (index != -1) {
    Object[] tmp=new Object[listenerList.length - 2];
    System.arraycopy(listenerList,0,tmp,0,index);
    if (index < tmp.length)     System.arraycopy(listenerList,index + 2,tmp,index,tmp.length - index);
    listenerList=(tmp.length == 0) ? NULL_ARRAY : tmp;
  }
}

Fixed version (ground truth):
/** 
 * Removes the listener as a listener of the specified type.
 * @param < T > the type of {@code EventListener}
 * @param t the type of the listener to be removed
 * @param l the listener to be removed
 */
public synchronized <T extends EventListener>void remove(Class<T> t,T l){
  if (l == null) {
    return;
  }
  if (!t.isInstance(l)) {
    throw new IllegalArgumentException("String_Node_Str" + l + "String_Node_Str"+ t);
  }
  int index=-1;
  for (int i=listenerList.length - 2; i >= 0; i-=2) {
    if ((listenerList[i] == t) && (listenerList[i + 1].equals(l) == true)) {
      index=i;
      break;
    }
  }
  if (index != -1) {
    Object[] tmp=new Object[listenerList.length - 2];
    System.arraycopy(listenerList,0,tmp,0,index);
    if (index < tmp.length)     System.arraycopy(listenerList,index + 2,tmp,index,tmp.length - index);
    listenerList=(tmp.length == 0) ? NULL_ARRAY : tmp;
  }
}
Program: 36047
Project: 36047
Buggy source:
/** 
 * Get the description of the link as a string. This may be useful if a URL can't be formed from the description, in which case the associated URL would be null.
 */
public String getDescription(){
  return desc;
}

Fixed version (ground truth):
/** 
 * Get the description of the link as a string. This may be useful if a URL can't be formed from the description, in which case the associated URL would be null.
 * @return the description of this link as a {@code String}
 */
public String getDescription(){
  return desc;
}
Program: 36048
Project: 36048
Buggy source:
/** 
 * Invoked when a internal frame has been opened.
 * @see javax.swing.JInternalFrame#show
 */
public void internalFrameOpened(InternalFrameEvent e);

Fixed version (ground truth):
/** 
 * Invoked when a internal frame has been opened.
 * @param e an {@code InternalFrameEvent} with information about the{@code JInteralFrame} that originated the event
 * @see javax.swing.JInternalFrame#show
 */
public void internalFrameOpened(InternalFrameEvent e);
Program: 36049
Project: 36049
Buggy source:
/** 
 * Invoked when an internal frame is activated.
 * @see javax.swing.JInternalFrame#setSelected
 */
public void internalFrameActivated(InternalFrameEvent e);

Fixed version (ground truth):
/** 
 * Invoked when an internal frame is activated.
 * @param e an {@code InternalFrameEvent} with information about the{@code JInteralFrame} that originated the event
 * @see javax.swing.JInternalFrame#setSelected
 */
public void internalFrameActivated(InternalFrameEvent e);
Program: 36050
Project: 36050
Buggy source:
/** 
 * Invoked when an internal frame is de-activated.
 * @see javax.swing.JInternalFrame#setSelected
 */
public void internalFrameDeactivated(InternalFrameEvent e);

Fixed version (ground truth):
/** 
 * Invoked when an internal frame is de-activated.
 * @param e an {@code InternalFrameEvent} with information about the{@code JInteralFrame} that originated the event
 * @see javax.swing.JInternalFrame#setSelected
 */
public void internalFrameDeactivated(InternalFrameEvent e);
Program: 36051
Project: 36051
Buggy source:
/** 
 * Invoked when an internal frame has been closed.
 * @see javax.swing.JInternalFrame#setClosed
 */
public void internalFrameClosed(InternalFrameEvent e);

Fixed version (ground truth):
/** 
 * Invoked when an internal frame has been closed.
 * @param e an {@code InternalFrameEvent} with information about the{@code JInteralFrame} that originated the event
 * @see javax.swing.JInternalFrame#setClosed
 */
public void internalFrameClosed(InternalFrameEvent e);
Program: 36052
Project: 36052
Buggy source:
/** 
 * Invoked when an internal frame is iconified.
 * @see javax.swing.JInternalFrame#setIcon
 */
public void internalFrameIconified(InternalFrameEvent e);

Fixed version (ground truth):
/** 
 * Invoked when an internal frame is iconified.
 * @param e an {@code InternalFrameEvent} with information about the{@code JInteralFrame} that originated the event
 * @see javax.swing.JInternalFrame#setIcon
 */
public void internalFrameIconified(InternalFrameEvent e);
Program: 36053
Project: 36053
Buggy source:
/** 
 * Invoked when an internal frame is de-iconified.
 * @see javax.swing.JInternalFrame#setIcon
 */
public void internalFrameDeiconified(InternalFrameEvent e);

Fixed version (ground truth):
/** 
 * Invoked when an internal frame is de-iconified.
 * @param e an {@code InternalFrameEvent} with information about the{@code JInteralFrame} that originated the event
 * @see javax.swing.JInternalFrame#setIcon
 */
public void internalFrameDeiconified(InternalFrameEvent e);
Program: 36054
Project: 36054
Buggy source:
/** 
 * Invoked when an internal frame is in the process of being closed. The close operation can be overridden at this point.
 * @see javax.swing.JInternalFrame#setDefaultCloseOperation
 */
public void internalFrameClosing(InternalFrameEvent e);

Fixed version (ground truth):
/** 
 * Invoked when an internal frame is in the process of being closed. The close operation can be overridden at this point.
 * @param e an {@code InternalFrameEvent} with information about the{@code JInteralFrame} that originated the event
 * @see javax.swing.JInternalFrame#setDefaultCloseOperation
 */
public void internalFrameClosing(InternalFrameEvent e);
Program: 36055
Project: 36055
Buggy source:
/** 
 * Represents a change in selection status between   {@code firstIndex} and{@code lastIndex}, inclusive.   {@code firstIndex} is less than or equal to{@code lastIndex}. The selection of at least one index within the range will have changed.
 * @param firstIndex the first index in the range, &lt;= lastIndex
 * @param lastIndex the last index in the range, &gt;= firstIndex
 * @param isAdjusting whether or not this is one in a series ofmultiple events, where changes are still being made
 */
public ListSelectionEvent(Object source,int firstIndex,int lastIndex,boolean isAdjusting){
  super(source);
  this.firstIndex=firstIndex;
  this.lastIndex=lastIndex;
  this.isAdjusting=isAdjusting;
}

Fixed version (ground truth):
/** 
 * Represents a change in selection status between   {@code firstIndex} and{@code lastIndex}, inclusive.   {@code firstIndex} is less than or equal to{@code lastIndex}. The selection of at least one index within the range will have changed.
 * @param source the {@code Object} on which the event initially occurred
 * @param firstIndex the first index in the range, &lt;= lastIndex
 * @param lastIndex the last index in the range, &gt;= firstIndex
 * @param isAdjusting whether or not this is one in a series ofmultiple events, where changes are still being made
 */
public ListSelectionEvent(Object source,int firstIndex,int lastIndex,boolean isAdjusting){
  super(source);
  this.firstIndex=firstIndex;
  this.lastIndex=lastIndex;
  this.isAdjusting=isAdjusting;
}
Program: 36056
Project: 36056
Buggy source:
/** 
 * Invoked when a key has been released.
 */
void menuKeyReleased(MenuKeyEvent e);

Fixed version (ground truth):
/** 
 * Invoked when a key has been released.
 * @param e a {@code MenuKeyEvent}
 */
void menuKeyReleased(MenuKeyEvent e);
Program: 36057
Project: 36057
Buggy source:
/** 
 * Invoked when a key has been typed. This event occurs when a key press is followed by a key release.
 */
void menuKeyTyped(MenuKeyEvent e);

Fixed version (ground truth):
/** 
 * Invoked when a key has been typed. This event occurs when a key press is followed by a key release.
 * @param e a {@code MenuKeyEvent}
 */
void menuKeyTyped(MenuKeyEvent e);
Program: 36058
Project: 36058
Buggy source:
/** 
 * Invoked when a key has been pressed.
 */
void menuKeyPressed(MenuKeyEvent e);

Fixed version (ground truth):
/** 
 * Invoked when a key has been pressed.
 * @param e a {@code MenuKeyEvent}
 */
void menuKeyPressed(MenuKeyEvent e);
Program: 36059
Project: 36059
Buggy source:
/** 
 * This method is called before the popup menu becomes visible
 */
void popupMenuWillBecomeVisible(PopupMenuEvent e);

Fixed version (ground truth):
/** 
 * This method is called before the popup menu becomes visible
 * @param e a {@code PopupMenuEvent} containing the source of the event
 */
void popupMenuWillBecomeVisible(PopupMenuEvent e);
Program: 36060
Project: 36060
Buggy source:
/** 
 * This method is called when the popup menu is canceled
 */
void popupMenuCanceled(PopupMenuEvent e);

Fixed version (ground truth):
/** 
 * This method is called when the popup menu is canceled
 * @param e a {@code PopupMenuEvent} containing the source of the event
 */
void popupMenuCanceled(PopupMenuEvent e);
Program: 36061
Project: 36061
Buggy source:
/** 
 * This method is called before the popup menu becomes invisible Note that a JPopupMenu can become invisible any time
 */
void popupMenuWillBecomeInvisible(PopupMenuEvent e);

Fixed version (ground truth):
/** 
 * This method is called before the popup menu becomes invisible Note that a JPopupMenu can become invisible any time
 * @param e a {@code PopupMenuEvent} containing the source of the event
 */
void popupMenuWillBecomeInvisible(PopupMenuEvent e);
Program: 36062
Project: 36062
Buggy source:
/** 
 * Returns the fromIndex.  Valid for removed or moved events 
 */
public int getFromIndex(){
  return fromIndex;
}

Fixed version (ground truth):
/** 
 * Returns the fromIndex.  Valid for removed or moved events
 * @return int value for index from which the column was moved or removed
 */
public int getFromIndex(){
  return fromIndex;
}
Program: 36063
Project: 36063
Buggy source:
/** 
 * Returns the toIndex.  Valid for add and moved events 
 */
public int getToIndex(){
  return toIndex;
}

Fixed version (ground truth):
/** 
 * Returns the toIndex.  Valid for add and moved events
 * @return int value of column's new index
 */
public int getToIndex(){
  return toIndex;
}
Program: 36064
Project: 36064
Buggy source:
/** 
 * Tells listeners that a column was repositioned. 
 */
public void columnMoved(TableColumnModelEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that a column was repositioned.
 * @param e a {@code TableColumnModelEvent}
 */
public void columnMoved(TableColumnModelEvent e);
Program: 36065
Project: 36065
Buggy source:
/** 
 * Tells listeners that the selection model of the TableColumnModel changed.
 */
public void columnSelectionChanged(ListSelectionEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that the selection model of the TableColumnModel changed.
 * @param e a {@code ListSelectionEvent}
 */
public void columnSelectionChanged(ListSelectionEvent e);
Program: 36066
Project: 36066
Buggy source:
/** 
 * Tells listeners that a column was removed from the model. 
 */
public void columnRemoved(TableColumnModelEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that a column was removed from the model.
 * @param e a {@code TableColumnModelEvent}
 */
public void columnRemoved(TableColumnModelEvent e);
Program: 36067
Project: 36067
Buggy source:
/** 
 * Tells listeners that a column was moved due to a margin change. 
 */
public void columnMarginChanged(ChangeEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that a column was moved due to a margin change.
 * @param e a {@code ChangeEvent}
 */
public void columnMarginChanged(ChangeEvent e);
Program: 36068
Project: 36068
Buggy source:
/** 
 * Tells listeners that a column was added to the model. 
 */
public void columnAdded(TableColumnModelEvent e);

Fixed version (ground truth):
/** 
 * Tells listeners that a column was added to the model.
 * @param e a {@code TableColumnModelEvent}
 */
public void columnAdded(TableColumnModelEvent e);
Program: 36069
Project: 36069
Buggy source:
protected void init(String text,Icon icon){
  if (text != null) {
    setText(text);
  }
  if (icon != null) {
    setIcon(icon);
  }
  updateUI();
  setAlignmentX(LEFT_ALIGNMENT);
  setAlignmentY(CENTER_ALIGNMENT);
}

Fixed version (ground truth):
/** 
 * Initialization of the   {@code AbstractButton}.
 * @param text  the text of the button
 * @param icon  the Icon image to display on the button
 */
protected void init(String text,Icon icon){
  if (text != null) {
    setText(text);
  }
  if (icon != null) {
    setIcon(icon);
  }
  updateUI();
  setAlignmentX(LEFT_ALIGNMENT);
  setAlignmentY(CENTER_ALIGNMENT);
}
Program: 36070
Project: 36070
Buggy source:
protected ItemListener createItemListener(){
  return getHandler();
}

Fixed version (ground truth):
/** 
 * Returns   {@code ItemListener} that is added to model.
 * @return the {@code ItemListener}
 */
protected ItemListener createItemListener(){
  return getHandler();
}
Program: 36071
Project: 36071
Buggy source:
/** 
 * If both the icon and text properties are set, this property defines the space between them. <p> The default value of this property is 4 pixels. <p> This is a JavaBeans bound property.
 * @since 1.4
 * @see #getIconTextGap
 * @beaninfo bound: true attribute: visualUpdate true description: If both the icon and text properties are set, this property defines the space between them.
 */
public void setIconTextGap(int iconTextGap){
  int oldValue=this.iconTextGap;
  this.iconTextGap=iconTextGap;
  iconTextGapSet=true;
  firePropertyChange("String_Node_Str",oldValue,iconTextGap);
  if (iconTextGap != oldValue) {
    revalidate();
    repaint();
  }
}

Fixed version (ground truth):
/** 
 * If both the icon and text properties are set, this property defines the space between them. <p> The default value of this property is 4 pixels. <p> This is a JavaBeans bound property.
 * @param iconTextGap the space between icon and text if these properties are set.
 * @since 1.4
 * @see #getIconTextGap
 * @beaninfo bound: true attribute: visualUpdate true description: If both the icon and text properties are set, this property defines the space between them.
 */
public void setIconTextGap(int iconTextGap){
  int oldValue=this.iconTextGap;
  this.iconTextGap=iconTextGap;
  iconTextGapSet=true;
  firePropertyChange("String_Node_Str",oldValue,iconTextGap);
  if (iconTextGap != oldValue) {
    revalidate();
    repaint();
  }
}
Program: 36072
Project: 36072
Buggy source:
/** 
 * Creates and returns a <code>PropertyChangeListener</code> that is responsible for listening for changes from the specified <code>Action</code> and updating the appropriate properties. <p> <b>Warning:</b> If you subclass this do not create an anonymous inner class.  If you do the lifetime of the button will be tied to that of the <code>Action</code>.
 * @param a the button's action
 * @since 1.3
 * @see Action
 * @see #setAction
 */
protected PropertyChangeListener createActionPropertyChangeListener(Action a){
  return createActionPropertyChangeListener0(a);
}

Fixed version (ground truth):
/** 
 * Creates and returns a <code>PropertyChangeListener</code> that is responsible for listening for changes from the specified <code>Action</code> and updating the appropriate properties. <p> <b>Warning:</b> If you subclass this do not create an anonymous inner class.  If you do the lifetime of the button will be tied to that of the <code>Action</code>.
 * @param a the button's action
 * @return the {@code PropertyChangeListener}
 * @since 1.3
 * @see Action
 * @see #setAction
 */
protected PropertyChangeListener createActionPropertyChangeListener(Action a){
  return createActionPropertyChangeListener0(a);
}
Program: 36073
Project: 36073
Buggy source:
protected ActionListener createActionListener(){
  return getHandler();
}

Fixed version (ground truth):
/** 
 * Returns   {@code ActionListener} that is added to model.
 * @return the {@code ActionListener}
 */
protected ActionListener createActionListener(){
  return getHandler();
}
Program: 36074
Project: 36074
Buggy source:
/** 
 * Gets one of this object's properties using the associated key.
 * @see #putValue
 */
public Object getValue(String key);

Fixed version (ground truth):
/** 
 * Gets one of this object's properties using the associated key.
 * @param key a {@code String} containing the key
 * @return the {@code Object} value
 * @see #putValue
 */
public Object getValue(String key);