Java DataFlavor.equals(DataFlavor that)

Syntax

DataFlavor.equals(DataFlavor that) has the following syntax.

public boolean equals(DataFlavor that)

Example

In the following code shows how to use DataFlavor.equals(DataFlavor that) method.


import java.awt.datatransfer.DataFlavor;
/*w  w w  .j a  va  2 s  . c o  m*/
public class Main {

  public static void main(String[] args) {

    DataFlavor df = DataFlavor.stringFlavor;
    System.out.println (df.equals(DataFlavor.imageFlavor));
  }
}




















Home »
  Java Tutorial »
    java.awt.datatransfer »




Clipboard
ClipboardOwner
DataFlavor
Transferable