nus-yam/ex-repair huggingface dataset:
Program: 77059
Project: 77059
Buggy source:
/** 
 * Returns whether or not the window is located under the mouse pointer. The window is considered to be under the mouse pointer if it is showing on the screen, and the mouse pointer is above the part of the window that is not obscured by any other windows.
 */
boolean isWindowUnderMouse(Window w);

Fixed version (ground truth):
/** 
 * Returns whether or not the window is located under the mouse pointer. The window is considered to be under the mouse pointer if it is showing on the screen, and the mouse pointer is above the part of the window that is not obscured by any other windows.
 * @param w the window to check
 * @return whether or not the window is located under the mousepointer
 */
boolean isWindowUnderMouse(Window w);
Program: 77060
Project: 77060
Buggy source:
/** 
 * This method does two things: it fills the point fields with the current coordinates of the mouse cursor and returns the number of the screen device where the pointer is located. The number of the screen device is only returned for independent devices (which are not parts of a virtual screen device). For virtual screen devices, 0 is returned. Mouse coordinates are also calculated depending on whether or not the screen device is virtual. For virtual screen devices, pointer coordinates are calculated in the virtual coordinate system. Otherwise, coordinates are calculated in the coordinate system of the screen device where the pointer is located. See java.awt.GraphicsConfiguration documentation for more details about virtual screen devices.
 */
int fillPointWithCoords(Point point);

Fixed version (ground truth):
/** 
 * This method does two things: it fills the point fields with the current coordinates of the mouse cursor and returns the number of the screen device where the pointer is located. The number of the screen device is only returned for independent devices (which are not parts of a virtual screen device). For virtual screen devices, 0 is returned. Mouse coordinates are also calculated depending on whether or not the screen device is virtual. For virtual screen devices, pointer coordinates are calculated in the virtual coordinate system. Otherwise, coordinates are calculated in the coordinate system of the screen device where the pointer is located. See java.awt.GraphicsConfiguration documentation for more details about virtual screen devices.
 * @param point holder for the current coordinates of the mousecursor
 * @return the number of the screen device where the pointer islocated
 */
int fillPointWithCoords(Point point);
Program: 77061
Project: 77061
Buggy source:
/** 
 * Enables the per-pixel alpha support for the window.
 * @see Window#setBackground(Color)
 */
void setOpaque(boolean isOpaque);

Fixed version (ground truth):
/** 
 * Enables the per-pixel alpha support for the window.
 * @param isOpaque whether or not per-pixel alpha support isenabled
 * @see Window#setBackground(Color)
 */
void setOpaque(boolean isOpaque);
Program: 77062
Project: 77062
Buggy source:
/** 
 * Sets the level of opacity for the window.
 * @see Window#setOpacity(float)
 */
void setOpacity(float opacity);

Fixed version (ground truth):
/** 
 * Sets the level of opacity for the window.
 * @param opacity the level of opacity
 * @see Window#setOpacity(float)
 */
void setOpacity(float opacity);
Program: 77063
Project: 77063
Buggy source:
public native void declareTypes(long[] formats,SunClipboard newOwner);

Fixed version (ground truth):
private native void declareTypes(long[] formats,SunClipboard newOwner);
Program: 77064
Project: 77064
Buggy source:
protected void unregisterClipboardViewerChecked(){
}

Fixed version (ground truth):
@Override protected void unregisterClipboardViewerChecked(){
}
Program: 77065
Project: 77065
Buggy source:
private void notifyLostOwnership(){
  lostOwnershipImpl();
}

Fixed version (ground truth):
/** 
 * Native Callbacks 
 */
private void notifyLostOwnership(){
  lostOwnershipImpl();
}
Program: 77066
Project: 77066
Buggy source:
protected void registerClipboardViewerChecked(){
}

Fixed version (ground truth):
@Override protected void registerClipboardViewerChecked(){
}
Program: 77067
Project: 77067
Buggy source:
protected void setContentsNative(Transferable contents){
  DataTransferer dataTransferer=DataTransferer.getInstance();
  long[] formatArray=dataTransferer.getFormatsForTransferableAsArray(contents,flavorMap);
  declareTypes(formatArray,this);
  Map<Long,DataFlavor> formatMap=dataTransferer.getFormatsForTransferable(contents,flavorMap);
  for (  Map.Entry<Long,DataFlavor> entry : formatMap.entrySet()) {
    long format=entry.getKey();
    DataFlavor flavor=entry.getValue();
    try {
      byte[] bytes=DataTransferer.getInstance().translateTransferable(contents,flavor,format);
      setData(bytes,format);
    }
 catch (    IOException e) {
      if (!(flavor.isMimeTypeEqual(DataFlavor.javaJVMLocalObjectMimeType) && e instanceof NotSerializableException)) {
        e.printStackTrace();
      }
    }
  }
  notifyChanged();
}

Fixed version (ground truth):
@Override protected void setContentsNative(Transferable contents){
  DataTransferer dataTransferer=DataTransferer.getInstance();
  long[] formatArray=dataTransferer.getFormatsForTransferableAsArray(contents,flavorMap);
  declareTypes(formatArray,this);
  Map<Long,DataFlavor> formatMap=dataTransferer.getFormatsForTransferable(contents,flavorMap);
  for (  Map.Entry<Long,DataFlavor> entry : formatMap.entrySet()) {
    long format=entry.getKey();
    DataFlavor flavor=entry.getValue();
    try {
      byte[] bytes=DataTransferer.getInstance().translateTransferable(contents,flavor,format);
      setData(bytes,format);
    }
 catch (    IOException e) {
      if (!(flavor.isMimeTypeEqual(DataFlavor.javaJVMLocalObjectMimeType) && e instanceof NotSerializableException)) {
        e.printStackTrace();
      }
    }
  }
  notifyChanged();
}
Program: 77068
Project: 77068
Buggy source:
public native void setData(byte[] data,long format);

Fixed version (ground truth):
private native void setData(byte[] data,long format);
Program: 77069
Project: 77069
Buggy source:
/** 
 * Invokes native check whether a change count on the general pasteboard is different than when we set it. The different count value means the current owner lost pasteboard ownership and someone else put data on the clipboard.
 * @since 1.7
 */
public native void checkPasteboard();

Fixed version (ground truth):
/** 
 * Invokes native check whether a change count on the general pasteboard is different than when we set it. The different count value means the current owner lost pasteboard ownership and someone else put data on the clipboard.
 * @since 1.7
 */
native void checkPasteboard();
Program: 77070
Project: 77070
Buggy source:
public long getID(){
  return 0;
}

Fixed version (ground truth):
@Override public long getID(){
  return 0;
}
Program: 77071
Project: 77071
Buggy source:
protected native byte[] getClipboardData(long format) throws IOException ;

Fixed version (ground truth):
@Override protected native byte[] getClipboardData(long format) throws IOException ;
Program: 77072
Project: 77072
Buggy source:
protected native long[] getClipboardFormats();

Fixed version (ground truth):
@Override protected native long[] getClipboardFormats();
Program: 77073
Project: 77073
Buggy source:
protected void clearNativeContext(){
}

Fixed version (ground truth):
@Override protected void clearNativeContext(){
}
Program: 77074
Project: 77074
Buggy source:
/** 
 * Clones the <code>PageFormat</code> argument and alters the clone to describe a default page size and orientation.
 * @param page the <code>PageFormat</code> to be cloned and altered
 * @return clone of <code>page</code>, altered to describe a default<code>PageFormat</code>.
 */
public PageFormat defaultPage(PageFormat page){
  PageFormat newPage=(PageFormat)page.clone();
  getDefaultPage(newPage);
  return newPage;
}

Fixed version (ground truth):
/** 
 * Clones the <code>PageFormat</code> argument and alters the clone to describe a default page size and orientation.
 * @param page the <code>PageFormat</code> to be cloned and altered
 * @return clone of <code>page</code>, altered to describe a default<code>PageFormat</code>.
 */
@Override public PageFormat defaultPage(PageFormat page){
  PageFormat newPage=(PageFormat)page.clone();
  getDefaultPage(newPage);
  return newPage;
}
Program: 77075
Project: 77075
Buggy source:
/** 
 * validate the paper size against the current printer.
 */
protected native void validatePaper(Paper origPaper,Paper newPaper);

Fixed version (ground truth):
/** 
 * validate the paper size against the current printer.
 */
@Override protected native void validatePaper(Paper origPaper,Paper newPaper);
Program: 77076
Project: 77076
Buggy source:
/** 
 * Called by the print() method at the start of a print job.
 */
protected void startDoc() throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}

Fixed version (ground truth):
/** 
 * Called by the print() method at the start of a print job.
 */
@Override protected void startDoc() throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}
Program: 77077
Project: 77077
Buggy source:
/** 
 * Displays a dialog that allows modification of a <code>PageFormat</code> instance. The <code>page</code> argument is used to initialize controls in the page setup dialog. If the user cancels the dialog then this method returns the original <code>page</code> object unmodified. If the user okays the dialog then this method returns a new <code>PageFormat</code> object with the indicated changes. In either case, the original <code>page</code> object is not modified.
 * @param page the default <code>PageFormat</code> presented to theuser for modification
 * @return    the original <code>page</code> object if the dialogis cancelled; a new <code>PageFormat</code> object containing the format indicated by the user if the dialog is acknowledged.
 * @exception HeadlessException if GraphicsEnvironment.isHeadless()returns true.
 * @see java.awt.GraphicsEnvironment#isHeadless
 * @since     1.2
 */
public PageFormat pageDialog(PageFormat page) throws HeadlessException {
  if (GraphicsEnvironment.isHeadless()) {
    throw new HeadlessException();
  }
  if (noDefaultPrinter) {
    return page;
  }
  if (getPrintService() instanceof StreamPrintService) {
    return super.pageDialog(page);
  }
  PageFormat pageClone=(PageFormat)page.clone();
  boolean doIt=pageSetup(pageClone,null);
  return doIt ? pageClone : page;
}

Fixed version (ground truth):
/** 
 * Displays a dialog that allows modification of a <code>PageFormat</code> instance. The <code>page</code> argument is used to initialize controls in the page setup dialog. If the user cancels the dialog then this method returns the original <code>page</code> object unmodified. If the user okays the dialog then this method returns a new <code>PageFormat</code> object with the indicated changes. In either case, the original <code>page</code> object is not modified.
 * @param page the default <code>PageFormat</code> presented to theuser for modification
 * @return    the original <code>page</code> object if the dialogis cancelled; a new <code>PageFormat</code> object containing the format indicated by the user if the dialog is acknowledged.
 * @exception HeadlessException if GraphicsEnvironment.isHeadless()returns true.
 * @see java.awt.GraphicsEnvironment#isHeadless
 * @since     1.2
 */
@Override public PageFormat pageDialog(PageFormat page) throws HeadlessException {
  if (GraphicsEnvironment.isHeadless()) {
    throw new HeadlessException();
  }
  if (noDefaultPrinter) {
    return page;
  }
  if (getPrintService() instanceof StreamPrintService) {
    return super.pageDialog(page);
  }
  PageFormat pageClone=(PageFormat)page.clone();
  boolean doIt=pageSetup(pageClone,null);
  return doIt ? pageClone : page;
}
Program: 77078
Project: 77078
Buggy source:
protected void setAttributes(PrintRequestAttributeSet attributes) throws PrinterException {
  super.setAttributes(attributes);
  if (attributes == null) {
    return;
  }
  NSPrintInfo nsPrintInfo=(NSPrintInfo)attributes.get(NSPrintInfo.class);
  if (nsPrintInfo != null) {
    fNSPrintInfo=nsPrintInfo.getValue();
  }
  PageRanges pageRangesAttr=(PageRanges)attributes.get(PageRanges.class);
  if (isSupportedValue(pageRangesAttr,attributes)) {
    SunPageSelection rangeSelect=(SunPageSelection)attributes.get(SunPageSelection.class);
    if (rangeSelect == null || rangeSelect == SunPageSelection.RANGE) {
      int[][] range=pageRangesAttr.getMembers();
      setPageRange(range[0][0] - 1,range[0][1] - 1);
    }
  }
}

Fixed version (ground truth):
@Override protected void setAttributes(PrintRequestAttributeSet attributes) throws PrinterException {
  super.setAttributes(attributes);
  if (attributes == null) {
    return;
  }
  NSPrintInfo nsPrintInfo=(NSPrintInfo)attributes.get(NSPrintInfo.class);
  if (nsPrintInfo != null) {
    fNSPrintInfo=nsPrintInfo.getValue();
  }
  PageRanges pageRangesAttr=(PageRanges)attributes.get(PageRanges.class);
  if (isSupportedValue(pageRangesAttr,attributes)) {
    SunPageSelection rangeSelect=(SunPageSelection)attributes.get(SunPageSelection.class);
    if (rangeSelect == null || rangeSelect == SunPageSelection.RANGE) {
      int[][] range=pageRangesAttr.getMembers();
      setPageRange(range[0][0] - 1,range[0][1] - 1);
    }
  }
}
Program: 77079
Project: 77079
Buggy source:
/** 
 * Called by the print() method at the end of a print job.
 */
protected void endDoc() throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}

Fixed version (ground truth):
/** 
 * Called by the print() method at the end of a print job.
 */
@Override protected void endDoc() throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}
Program: 77080
Project: 77080
Buggy source:
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
protected double getPhysicalPageHeight(Paper p){
  return 0;
}

Fixed version (ground truth):
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
@Override protected double getPhysicalPageHeight(Paper p){
  return 0;
}
Program: 77081
Project: 77081
Buggy source:
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
protected double getPhysicalPrintableY(Paper p){
  return 0;
}

Fixed version (ground truth):
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
@Override protected double getPhysicalPrintableY(Paper p){
  return 0;
}
Program: 77082
Project: 77082
Buggy source:
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
protected double getPhysicalPrintableX(Paper p){
  return 0;
}

Fixed version (ground truth):
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
@Override protected double getPhysicalPrintableX(Paper p){
  return 0;
}
Program: 77083
Project: 77083
Buggy source:
/** 
 * Returns the resolution in dots per inch down the height of the page.
 */
protected double getYRes(){
  return 0;
}

Fixed version (ground truth):
/** 
 * Returns the resolution in dots per inch down the height of the page.
 */
@Override protected double getYRes(){
  return 0;
}
Program: 77084
Project: 77084
Buggy source:
/** 
 * Prints the contents of the array of ints, 'data' to the current page. The band is placed at the location (x, y) in device coordinates on the page. The width and height of the band is specified by the caller.
 */
protected void printBand(byte[] data,int x,int y,int width,int height) throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}

Fixed version (ground truth):
/** 
 * Prints the contents of the array of ints, 'data' to the current page. The band is placed at the location (x, y) in device coordinates on the page. The width and height of the band is specified by the caller.
 */
@Override protected void printBand(byte[] data,int x,int y,int width,int height) throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}
Program: 77085
Project: 77085
Buggy source:
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
protected double getPhysicalPrintableWidth(Paper p){
  return 0;
}

Fixed version (ground truth):
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
@Override protected double getPhysicalPrintableWidth(Paper p){
  return 0;
}
Program: 77086
Project: 77086
Buggy source:
/** 
 * Presents a dialog to the user for changing the properties of the print job. This method will display a native dialog if a native print service is selected, and user choice of printers will be restricted to these native print services. To present the cross platform print dialog for all services, including native ones instead use <code>printDialog(PrintRequestAttributeSet)</code>. <p> PrinterJob implementations which can use PrintService's will update the PrintService for this PrinterJob to reflect the new service selected by the user.
 * @return <code>true</code> if the user does not cancel the dialog;<code>false</code> otherwise.
 * @exception HeadlessException if GraphicsEnvironment.isHeadless()returns true.
 * @see java.awt.GraphicsEnvironment#isHeadless
 */
public boolean printDialog() throws HeadlessException {
  if (GraphicsEnvironment.isHeadless()) {
    throw new HeadlessException();
  }
  if (noDefaultPrinter) {
    return false;
  }
  if (attributes == null) {
    attributes=new HashPrintRequestAttributeSet();
  }
  if (getPrintService() instanceof StreamPrintService) {
    return super.printDialog(attributes);
  }
  return jobSetup(getPageable(),checkAllowedToPrintToFile());
}

Fixed version (ground truth):
/** 
 * Presents a dialog to the user for changing the properties of the print job. This method will display a native dialog if a native print service is selected, and user choice of printers will be restricted to these native print services. To present the cross platform print dialog for all services, including native ones instead use <code>printDialog(PrintRequestAttributeSet)</code>. <p> PrinterJob implementations which can use PrintService's will update the PrintService for this PrinterJob to reflect the new service selected by the user.
 * @return <code>true</code> if the user does not cancel the dialog;<code>false</code> otherwise.
 * @exception HeadlessException if GraphicsEnvironment.isHeadless()returns true.
 * @see java.awt.GraphicsEnvironment#isHeadless
 */
@Override public boolean printDialog() throws HeadlessException {
  if (GraphicsEnvironment.isHeadless()) {
    throw new HeadlessException();
  }
  if (noDefaultPrinter) {
    return false;
  }
  if (attributes == null) {
    attributes=new HashPrintRequestAttributeSet();
  }
  if (getPrintService() instanceof StreamPrintService) {
    return super.printDialog(attributes);
  }
  return jobSetup(getPageable(),checkAllowedToPrintToFile());
}
Program: 77088
Project: 77088
Buggy source:
protected native void abortDoc();

Fixed version (ground truth):
@Override protected native void abortDoc();
Program: 77089
Project: 77089
Buggy source:
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
protected double getPhysicalPageWidth(Paper p){
  return 0;
}

Fixed version (ground truth):
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
@Override protected double getPhysicalPageWidth(Paper p){
  return 0;
}
Program: 77090
Project: 77090
Buggy source:
/** 
 * Returns the resolution in dots per inch across the width of the page.
 */
protected double getXRes(){
  return 0;
}

Fixed version (ground truth):
/** 
 * Returns the resolution in dots per inch across the width of the page.
 */
@Override protected double getXRes(){
  return 0;
}
Program: 77091
Project: 77091
Buggy source:
protected void finalize(){
  if (fNSPrintInfo != -1) {
    dispose(fNSPrintInfo);
  }
}

Fixed version (ground truth):
@Override protected void finalize(){
  if (fNSPrintInfo != -1) {
    dispose(fNSPrintInfo);
  }
}
Program: 77092
Project: 77092
Buggy source:
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
protected double getPhysicalPrintableHeight(Paper p){
  return 0;
}

Fixed version (ground truth):
/** 
 * Must be obtained from the current printer. Value is in device pixels. Not adjusted for orientation of the paper.
 */
@Override protected double getPhysicalPrintableHeight(Paper p){
  return 0;
}
Program: 77093
Project: 77093
Buggy source:
/** 
 * End a page.
 */
protected void endPage(PageFormat format,Printable painter,int index) throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}

Fixed version (ground truth):
/** 
 * End a page.
 */
@Override protected void endPage(PageFormat format,Printable painter,int index) throws PrinterException {
  throw new PrinterException(sShouldNotReachHere);
}
Program: 77094
Project: 77094
Buggy source:
protected native boolean showDialog();

Fixed version (ground truth):
@Override protected native boolean showDialog();
Program: 77095
Project: 77095
Buggy source:
protected native boolean showDialog();

Fixed version (ground truth):
@Override protected native boolean showDialog();
Program: 77096
Project: 77096
Buggy source:
public static SurfaceData createData(PageFormat pf,long context){
  return new CPrinterSurfaceData(CPrinterGraphicsConfig.getConfig(pf),context);
}

Fixed version (ground truth):
static SurfaceData createData(PageFormat pf,long context){
  return new CPrinterSurfaceData(CPrinterGraphicsConfig.getConfig(pf),context);
}
Program: 77097
Project: 77097
Buggy source:
public CPrinterSurfaceData(GraphicsConfiguration gc,long context){
  super(IntRgbPQ,gc.getColorModel(),gc,gc.getBounds());
  initOps(context,this.fGraphicsStates,this.fGraphicsStatesObject,gc.getBounds().width,gc.getBounds().height);
}

Fixed version (ground truth):
private CPrinterSurfaceData(GraphicsConfiguration gc,long context){
  super(IntRgbPQ,gc.getColorModel(),gc,gc.getBounds());
  initOps(context,this.fGraphicsStates,this.fGraphicsStatesObject,gc.getBounds().width,gc.getBounds().height);
}
Program: 77098
Project: 77098
Buggy source:
/** 
 * Returns the name of this clipboard object.
 * @see java.awt.Toolkit#getSystemClipboard
 */
public String getName(){
  return name;
}

Fixed version (ground truth):
/** 
 * Returns the name of this clipboard object.
 * @return the name of this clipboard object
 * @see java.awt.Toolkit#getSystemClipboard
 */
public String getName(){
  return name;
}
Program: 77099
Project: 77099
Buggy source:
/** 
 * Creates a clipboard object.
 * @see java.awt.Toolkit#getSystemClipboard
 */
public Clipboard(String name){
  this.name=name;
}

Fixed version (ground truth):
/** 
 * Creates a clipboard object.
 * @param name for the clipboard
 * @see java.awt.Toolkit#getSystemClipboard
 */
public Clipboard(String name){
  this.name=name;
}
Program: 77100
Project: 77100
Buggy source:
public final Class<?> getDefaultRepresentationClass(){
  return ioInputStreamClass;
}

Fixed version (ground truth):
/** 
 * Returns the default representation class.
 * @return the default representation class
 */
public final Class<?> getDefaultRepresentationClass(){
  return ioInputStreamClass;
}
Program: 77101
Project: 77101
Buggy source:
/** 
 * Called on <code>DataFlavor</code> for every MIME Type parameter to allow <code>DataFlavor</code> subclasses to handle special parameters like the text/plain <code>charset</code> parameters, whose values are case insensitive.  (MIME type parameter values are supposed to be case sensitive. <p> This method is called for each parameter name/value pair and should return the normalized representation of the <code>parameterValue</code>. This method is never invoked by this implementation from 1.1 onwards.
 * @deprecated
 */
@Deprecated protected String normalizeMimeTypeParameter(String parameterName,String parameterValue){
  return parameterValue;
}

Fixed version (ground truth):
/** 
 * Called on <code>DataFlavor</code> for every MIME Type parameter to allow <code>DataFlavor</code> subclasses to handle special parameters like the text/plain <code>charset</code> parameters, whose values are case insensitive.  (MIME type parameter values are supposed to be case sensitive. <p> This method is called for each parameter name/value pair and should return the normalized representation of the <code>parameterValue</code>. This method is never invoked by this implementation from 1.1 onwards.
 * @param parameterName the parameter name
 * @param parameterValue the parameter value
 * @return the parameter value
 * @deprecated
 */
@Deprecated protected String normalizeMimeTypeParameter(String parameterName,String parameterValue){
  return parameterValue;
}
Program: 77102
Project: 77102
Buggy source:
public final String getDefaultRepresentationClassAsString(){
  return getDefaultRepresentationClass().getName();
}

Fixed version (ground truth):
/** 
 * Returns the name of the default representation class.
 * @return the name of the default representation class
 */
public final String getDefaultRepresentationClassAsString(){
  return getDefaultRepresentationClass().getName();
}
Program: 77103
Project: 77103
Buggy source:
/** 
 * Returns whether the representation class for this <code>DataFlavor</code> is <code>java.nio.CharBuffer</code> or a subclass thereof.
 * @since 1.4
 */
public boolean isRepresentationClassCharBuffer(){
  return java.nio.CharBuffer.class.isAssignableFrom(representationClass);
}

Fixed version (ground truth):
/** 
 * Returns whether the representation class for this <code>DataFlavor</code> is <code>java.nio.CharBuffer</code> or a subclass thereof.
 * @return whether or not the representation class for this{@code DataFlavor} is {@code java.nio.CharBuffer} or a subclassthereof
 * @since 1.4
 */
public boolean isRepresentationClassCharBuffer(){
  return java.nio.CharBuffer.class.isAssignableFrom(representationClass);
}
Program: 77104
Project: 77104
Buggy source:
/** 
 * Returns whether the representation class for this <code>DataFlavor</code> is <code>java.nio.ByteBuffer</code> or a subclass thereof.
 * @since 1.4
 */
public boolean isRepresentationClassByteBuffer(){
  return java.nio.ByteBuffer.class.isAssignableFrom(representationClass);
}

Fixed version (ground truth):
/** 
 * Returns whether the representation class for this <code>DataFlavor</code> is <code>java.nio.ByteBuffer</code> or a subclass thereof.
 * @return whether or not the representation class for this{@code DataFlavor} is {@code java.nio.ByteBuffer} or a subclassthereof
 * @since 1.4
 */
public boolean isRepresentationClassByteBuffer(){
  return java.nio.ByteBuffer.class.isAssignableFrom(representationClass);
}
Program: 77105
Project: 77105
Buggy source:
/** 
 * Called for each MIME type string to give <code>DataFlavor</code> subtypes the opportunity to change how the normalization of MIME types is accomplished.  One possible use would be to add default parameter/value pairs in cases where none are present in the MIME type string passed in. This method is never invoked by this implementation from 1.1 onwards.
 * @deprecated
 */
@Deprecated protected String normalizeMimeType(String mimeType){
  return mimeType;
}

Fixed version (ground truth):
/** 
 * Called for each MIME type string to give <code>DataFlavor</code> subtypes the opportunity to change how the normalization of MIME types is accomplished.  One possible use would be to add default parameter/value pairs in cases where none are present in the MIME type string passed in. This method is never invoked by this implementation from 1.1 onwards.
 * @param mimeType the mime type
 * @return the mime type
 * @deprecated
 */
@Deprecated protected String normalizeMimeType(String mimeType){
  return mimeType;
}
Program: 77106
Project: 77106
Buggy source:
/** 
 * Does the <code>DataFlavor</code> represent a serialized object?
 */
public boolean isMimeTypeSerializedObject(){
  return isMimeTypeEqual(javaSerializedObjectMimeType);
}

Fixed version (ground truth):
/** 
 * Does the <code>DataFlavor</code> represent a serialized object?
 * @return whether or not a serialized object is represented
 */
public boolean isMimeTypeSerializedObject(){
  return isMimeTypeEqual(javaSerializedObjectMimeType);
}
Program: 77107
Project: 77107
Buggy source:
/** 
 * Does the <code>DataFlavor</code> represent a <code>java.io.InputStream</code>?
 */
public boolean isRepresentationClassInputStream(){
  return ioInputStreamClass.isAssignableFrom(representationClass);
}

Fixed version (ground truth):
/** 
 * Does the <code>DataFlavor</code> represent a <code>java.io.InputStream</code>?
 * @return whether or not this {@code DataFlavor} represent a{@code java.io.InputStream}
 */
public boolean isRepresentationClassInputStream(){
  return ioInputStreamClass.isAssignableFrom(representationClass);
}
Program: 77108
Project: 77108
Buggy source:
/** 
 * Returns whether the representation class for this <code>DataFlavor</code> is <code>java.io.Reader</code> or a subclass thereof.
 * @since 1.4
 */
public boolean isRepresentationClassReader(){
  return java.io.Reader.class.isAssignableFrom(representationClass);
}

Fixed version (ground truth):
/** 
 * Returns whether the representation class for this <code>DataFlavor</code> is <code>java.io.Reader</code> or a subclass thereof.
 * @return whether or not the representation class for this{@code DataFlavor} is {@code java.io.Reader} or a subclassthereof
 * @since 1.4
 */
public boolean isRepresentationClassReader(){
  return java.io.Reader.class.isAssignableFrom(representationClass);
}
Program: 77109
Project: 77109
Buggy source:
/** 
 * Creates a <code>Transferable</code> capable of transferring the specified <code>String</code>.
 */
public StringSelection(String data){
  this.data=data;
}

Fixed version (ground truth):
/** 
 * Creates a <code>Transferable</code> capable of transferring the specified <code>String</code>.
 * @param data the string to be transferred
 */
public StringSelection(String data){
  this.data=data;
}
Program: 77110
Project: 77110
Buggy source:
/** 
 * Returns the default FlavorMap for this thread's ClassLoader.
 */
public static FlavorMap getDefaultFlavorMap(){
  ClassLoader contextClassLoader=Thread.currentThread().getContextClassLoader();
  if (contextClassLoader == null) {
    contextClassLoader=ClassLoader.getSystemClassLoader();
  }
  FlavorMap fm;
synchronized (flavorMaps) {
    fm=flavorMaps.get(contextClassLoader);
    if (fm == null) {
      fm=new SystemFlavorMap();
      flavorMaps.put(contextClassLoader,fm);
    }
  }
  return fm;
}

Fixed version (ground truth):
/** 
 * Returns the default FlavorMap for this thread's ClassLoader.
 * @return the default FlavorMap for this thread's ClassLoader
 */
public static FlavorMap getDefaultFlavorMap(){
  ClassLoader contextClassLoader=Thread.currentThread().getContextClassLoader();
  if (contextClassLoader == null) {
    contextClassLoader=ClassLoader.getSystemClassLoader();
  }
  FlavorMap fm;
synchronized (flavorMaps) {
    fm=flavorMaps.get(contextClassLoader);
    if (fm == null) {
      fm=new SystemFlavorMap();
      flavorMaps.put(contextClassLoader,fm);
    }
  }
  return fm;
}
Program: 77111
Project: 77111
Buggy source:
/** 
 * Decodes a <code>String</code> native for use as a <code>DataFlavor</code>.
 * @param nat the <code>String</code> to decode
 * @return the decoded <code>DataFlavor</code>, or <code>null</code> ifnat is not an encoded <code>String</code> native
 */
public static DataFlavor decodeDataFlavor(String nat) throws ClassNotFoundException {
  String retval_str=SystemFlavorMap.decodeJavaMIMEType(nat);
  return (retval_str != null) ? new DataFlavor(retval_str) : null;
}

Fixed version (ground truth):
/** 
 * Decodes a <code>String</code> native for use as a <code>DataFlavor</code>.
 * @param nat the <code>String</code> to decode
 * @return the decoded <code>DataFlavor</code>, or <code>null</code> ifnat is not an encoded <code>String</code> native
 * @throws ClassNotFoundException if the class of the data flavoris not loaded
 */
public static DataFlavor decodeDataFlavor(String nat) throws ClassNotFoundException {
  String retval_str=SystemFlavorMap.decodeJavaMIMEType(nat);
  return (retval_str != null) ? new DataFlavor(retval_str) : null;
}
Program: 77112
Project: 77112
Buggy source:
/** 
 * Returns an object which represents the data to be transferred.  The class of the object returned is defined by the representation class of the flavor.
 * @param flavor the requested flavor for the data
 * @see DataFlavor#getRepresentationClass
 * @exception IOException                if the data is no longer availablein the requested flavor.
 * @exception UnsupportedFlavorException if the requested data flavor isnot supported.
 */
public Object getTransferData(DataFlavor flavor) throws UnsupportedFlavorException, IOException ;

Fixed version (ground truth):
/** 
 * Returns an object which represents the data to be transferred.  The class of the object returned is defined by the representation class of the flavor.
 * @param flavor the requested flavor for the data
 * @return an object which represents the data to be transferred
 * @see DataFlavor#getRepresentationClass
 * @exception IOException                if the data is no longer availablein the requested flavor.
 * @exception UnsupportedFlavorException if the requested data flavor isnot supported.
 */
public Object getTransferData(DataFlavor flavor) throws UnsupportedFlavorException, IOException ;
Program: 77113
Project: 77113
Buggy source:
/** 
 * Gets all the objects currently registered as <code><em>Foo</em>Listener</code>s upon this <code>DragSource</code>. <code><em>Foo</em>Listener</code>s are registered using the <code>add<em>Foo</em>Listener</code> method.
 * @param listenerType the type of listeners requested; this parametershould 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 <code>DragSource</code>, or an empty array if no such listeners have been added
 * @exception ClassCastException if <code>listenerType</code>doesn't specify a class or interface that implements <code>java.util.EventListener</code>
 * @see #getDragSourceListeners
 * @see #getDragSourceMotionListeners
 * @since 1.4
 */
public <T extends EventListener>T[] getListeners(Class<T> listenerType){
  EventListener l=null;
  if (listenerType == DragSourceListener.class) {
    l=listener;
  }
 else   if (listenerType == DragSourceMotionListener.class) {
    l=motionListener;
  }
  return DnDEventMulticaster.getListeners(l,listenerType);
}

Fixed version (ground truth):
/** 
 * Gets all the objects currently registered as <code><em>Foo</em>Listener</code>s upon this <code>DragSource</code>. <code><em>Foo</em>Listener</code>s are registered using the <code>add<em>Foo</em>Listener</code> method.
 * @param < T > the type of listener objects
 * @param listenerType the type of listeners requested; this parametershould 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 <code>DragSource</code>, or an empty array if no such listeners have been added
 * @exception ClassCastException if <code>listenerType</code>doesn't specify a class or interface that implements <code>java.util.EventListener</code>
 * @see #getDragSourceListeners
 * @see #getDragSourceMotionListeners
 * @since 1.4
 */
public <T extends EventListener>T[] getListeners(Class<T> listenerType){
  EventListener l=null;
  if (listenerType == DragSourceListener.class) {
    l=listener;
  }
 else   if (listenerType == DragSourceMotionListener.class) {
    l=motionListener;
  }
  return DnDEventMulticaster.getListeners(l,listenerType);
}
Program: 77114
Project: 77114
Buggy source:
/** 
 * Creates a new <code>DragGestureRecognizer</code> that implements the specified abstract subclass of <code>DragGestureRecognizer</code>, and sets the specified <code>Component</code> and <code>DragGestureListener</code> on the newly created object. <P>
 * @param recognizerAbstractClass the requested abstract type
 * @param actions                 the permitted source drag actions
 * @param c                       the <code>Component</code> target
 * @param dgl        the <code>DragGestureListener</code> to notify<P>
 * @return the new <code>DragGestureRecognizer</code> or <code>null</code>if the <code>Toolkit.createDragGestureRecognizer</code> method has no implementation available for the requested <code>DragGestureRecognizer</code> subclass and returns <code>null</code>
 */
public <T extends DragGestureRecognizer>T createDragGestureRecognizer(Class<T> recognizerAbstractClass,Component c,int actions,DragGestureListener dgl){
  return Toolkit.getDefaultToolkit().createDragGestureRecognizer(recognizerAbstractClass,this,c,actions,dgl);
}

Fixed version (ground truth):
/** 
 * Creates a new <code>DragGestureRecognizer</code> that implements the specified abstract subclass of <code>DragGestureRecognizer</code>, and sets the specified <code>Component</code> and <code>DragGestureListener</code> on the newly created object. <P>
 * @param < T > the type of {@code DragGestureRecognizer} to create
 * @param recognizerAbstractClass the requested abstract type
 * @param actions                 the permitted source drag actions
 * @param c                       the <code>Component</code> target
 * @param dgl        the <code>DragGestureListener</code> to notify<P>
 * @return the new <code>DragGestureRecognizer</code> or <code>null</code>if the <code>Toolkit.createDragGestureRecognizer</code> method has no implementation available for the requested <code>DragGestureRecognizer</code> subclass and returns <code>null</code>
 */
public <T extends DragGestureRecognizer>T createDragGestureRecognizer(Class<T> recognizerAbstractClass,Component c,int actions,DragGestureListener dgl){
  return Toolkit.getDefaultToolkit().createDragGestureRecognizer(recognizerAbstractClass,this,c,actions,dgl);
}
Program: 77115
Project: 77115
Buggy source:
/** 
 * Creates the DropTargetContext associated with this DropTarget. Subclasses may override this method to instantiate their own DropTargetContext subclass. This call is typically *only* called by the platform's DropTargetContextPeer as a drag operation encounters this DropTarget. Accessing the Context while no Drag is current has undefined results.
 */
protected DropTargetContext createDropTargetContext(){
  return new DropTargetContext(this);
}

Fixed version (ground truth):
/** 
 * Creates the DropTargetContext associated with this DropTarget. Subclasses may override this method to instantiate their own DropTargetContext subclass. This call is typically *only* called by the platform's DropTargetContextPeer as a drag operation encounters this DropTarget. Accessing the Context while no Drag is current has undefined results.
 * @return the DropTargetContext associated with this DropTarget
 */
protected DropTargetContext createDropTargetContext(){
  return new DropTargetContext(this);
}
Program: 77116
Project: 77116
Buggy source:
/** 
 * create an embedded autoscroller <P>
 * @param c the <code>Component</code>
 * @param p the <code>Point</code>
 */
protected DropTargetAutoScroller createDropTargetAutoScroller(Component c,Point p){
  return new DropTargetAutoScroller(c,p);
}

Fixed version (ground truth):
/** 
 * create an embedded autoscroller
 * @param c the <code>Component</code>
 * @param p the <code>Point</code>
 * @return an embedded autoscroller
 */
protected DropTargetAutoScroller createDropTargetAutoScroller(Component c,Point p){
  return new DropTargetAutoScroller(c,p);
}
Program: 77117
Project: 77117
Buggy source:
/** 
 * return the current drag cursor
 */
Cursor getCursor();

Fixed version (ground truth):
/** 
 * return the current drag cursor
 * @return the current drag cursor
 */
Cursor getCursor();
Program: 77118
Project: 77118
Buggy source:
/** 
 * start a drag
 */
void startDrag(DragSourceContext dsc,Cursor c,Image dragImage,Point imageOffset) throws InvalidDnDOperationException ;

Fixed version (ground truth):
/** 
 * start a drag
 * @param dsc the DragSourceContext
 * @param c the cursor
 * @param dragImage the image to be dragged
 * @param imageOffset the offset
 */
void startDrag(DragSourceContext dsc,Cursor c,Image dragImage,Point imageOffset) throws InvalidDnDOperationException ;
Program: 77119
Project: 77119
Buggy source:
/** 
 * set the current drag cursor
 */
void setCursor(Cursor c) throws InvalidDnDOperationException ;

Fixed version (ground truth):
/** 
 * set the current drag cursor
 * @param c the cursor
 */
void setCursor(Cursor c) throws InvalidDnDOperationException ;
Program: 77120
Project: 77120
Buggy source:
/** 
 * @return if the DragSource Transferable is in the same JVM as the Target
 */
boolean isTransferableJVMLocal();

Fixed version (ground truth):
/** 
 * Return whether or not the DragSource Transferable is in the same JVM as the Target.
 * @return if the DragSource Transferable is in the same JVM as the Target
 */
boolean isTransferableJVMLocal();
Program: 77121
Project: 77121
Buggy source:
/** 
 * accept the Drop
 */
void acceptDrop(int dropAction);

Fixed version (ground truth):
/** 
 * accept the Drop
 * @param dropAction the drop action
 */
void acceptDrop(int dropAction);
Program: 77122
Project: 77122
Buggy source:
/** 
 * update the peer's notion of the Target's actions
 */
void setTargetActions(int actions);

Fixed version (ground truth):
/** 
 * update the peer's notion of the Target's actions
 * @param actions the actions
 */
void setTargetActions(int actions);
Program: 77123
Project: 77123
Buggy source:
/** 
 * get the current Target actions
 */
int getTargetActions();

Fixed version (ground truth):
/** 
 * get the current Target actions
 * @return the current Target actions
 */
int getTargetActions();
Program: 77124
Project: 77124
Buggy source:
/** 
 * accept the Drag
 */
void acceptDrag(int dragAction);

Fixed version (ground truth):
/** 
 * accept the Drag
 * @param dragAction the drag action
 */
void acceptDrag(int dragAction);
Program: 77125
Project: 77125
Buggy source:
/** 
 * get the DropTarget associated with this peer
 */
DropTarget getDropTarget();

Fixed version (ground truth):
/** 
 * get the DropTarget associated with this peer
 * @return the DropTarget associated with this peer
 */
DropTarget getDropTarget();
Program: 77126
Project: 77126
Buggy source:
/** 
 * signal complete
 */
void dropComplete(boolean success);

Fixed version (ground truth):
/** 
 * signal complete
 * @param success the signal
 */
void dropComplete(boolean success);
Program: 77127
Project: 77127
Buggy source:
/** 
 * get the (remote) DataFlavors from the peer
 */
DataFlavor[] getTransferDataFlavors();

Fixed version (ground truth):
/** 
 * get the (remote) DataFlavors from the peer
 * @return the (remote) DataFlavors from the peer
 */
DataFlavor[] getTransferDataFlavors();
Program: 77128
Project: 77128
Buggy source:
/** 
 * get an input stream to the remote data
 */
Transferable getTransferable() throws InvalidDnDOperationException ;

Fixed version (ground truth):
/** 
 * get an input stream to the remote data
 * @return an input stream to the remote data
 */
Transferable getTransferable() throws InvalidDnDOperationException ;
Program: 77129
Project: 77129
Buggy source:
/** 
 * Gets the value of the single specified service attribute. This may be useful to clients which only need the value of one attribute and want to minimize overhead.
 * @param category the category of a PrintServiceAttribute supportedby this service - may not be null.
 * @return the value of the supported attribute or null if theattribute is not supported by this service.
 * @exception NullPointerException if the category is null.
 * @exception IllegalArgumentException (unchecked exception) if <CODE>category</CODE> is not a <code>Class</code> that implements interface {@link javax.print.attribute.PrintServiceAttribute PrintServiceAttribute}.
 */
public <T extends PrintServiceAttribute>T getAttribute(Class<T> category);

Fixed version (ground truth):
/** 
 * Gets the value of the single specified service attribute. This may be useful to clients which only need the value of one attribute and want to minimize overhead.
 * @param < T > the type of the specified service attribute
 * @param category the category of a PrintServiceAttribute supportedby this service - may not be null.
 * @return the value of the supported attribute or null if theattribute is not supported by this service.
 * @exception NullPointerException if the category is null.
 * @exception IllegalArgumentException (unchecked exception) if <CODE>category</CODE> is not a <code>Class</code> that implements interface {@link javax.print.attribute.PrintServiceAttribute PrintServiceAttribute}.
 */
public <T extends PrintServiceAttribute>T getAttribute(Class<T> category);
Program: 77130
Project: 77130
Buggy source:
/** 
 * Invoked when an event is dispatched in the AWT.
 */
public void eventDispatched(AWTEvent event);

Fixed version (ground truth):
/** 
 * Invoked when an event is dispatched in the AWT.
 * @param event the event to be processed
 */
public void eventDispatched(AWTEvent event);
Program: 77131
Project: 77131
Buggy source:
/** 
 * Invoked when an action occurs.
 */
public void actionPerformed(ActionEvent e);

Fixed version (ground truth):
/** 
 * Invoked when an action occurs.
 * @param e the event to be processed
 */
public void actionPerformed(ActionEvent e);
Program: 77132
Project: 77132
Buggy source:
/** 
 * Invoked when the value of the adjustable has changed.
 */
public void adjustmentValueChanged(AdjustmentEvent e);

Fixed version (ground truth):
/** 
 * Invoked when the value of the adjustable has changed.
 * @param e the event to be processed
 */
public void adjustmentValueChanged(AdjustmentEvent e);
Program: 77133
Project: 77133
Buggy source:
/** 
 * Invoked when the component has been made invisible.
 */
public void componentHidden(ComponentEvent e);

Fixed version (ground truth):
/** 
 * Invoked when the component has been made invisible.
 * @param e the event to be processed
 */
public void componentHidden(ComponentEvent e);
Program: 77134
Project: 77134
Buggy source:
/** 
 * Invoked when the component's size changes.
 */
public void componentResized(ComponentEvent e);

Fixed version (ground truth):
/** 
 * Invoked when the component's size changes.
 * @param e the event to be processed
 */
public void componentResized(ComponentEvent e);
Program: 77135
Project: 77135
Buggy source:
/** 
 * Invoked when the component's position changes.
 */
public void componentMoved(ComponentEvent e);

Fixed version (ground truth):
/** 
 * Invoked when the component's position changes.
 * @param e the event to be processed
 */
public void componentMoved(ComponentEvent e);
Program: 77136
Project: 77136
Buggy source:
/** 
 * Invoked when the component has been made visible.
 */
public void componentShown(ComponentEvent e);

Fixed version (ground truth):
/** 
 * Invoked when the component has been made visible.
 * @param e the event to be processed
 */
public void componentShown(ComponentEvent e);
Program: 77137
Project: 77137
Buggy source:
/** 
 * Invoked when a component has been added to the container.
 */
public void componentAdded(ContainerEvent e);

Fixed version (ground truth):
/** 
 * Invoked when a component has been added to the container.
 * @param e the event to be processed
 */
public void componentAdded(ContainerEvent e);
Program: 77138
Project: 77138
Buggy source:
/** 
 * Invoked when a component has been removed from the container.
 */
public void componentRemoved(ContainerEvent e);

Fixed version (ground truth):
/** 
 * Invoked when a component has been removed from the container.
 * @param e the event to be processed
 */
public void componentRemoved(ContainerEvent e);
Program: 77139
Project: 77139
Buggy source:
/** 
 * Invoked when a component gains the keyboard focus.
 */
public void focusGained(FocusEvent e);

Fixed version (ground truth):
/** 
 * Invoked when a component gains the keyboard focus.
 * @param e the event to be processed
 */
public void focusGained(FocusEvent e);