Java DataFlavor.clone()

Syntax

DataFlavor.clone() has the following syntax.

public Object clone()  throws CloneNotSupportedException

Example

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


import java.awt.datatransfer.DataFlavor;
//  www.j  a v  a2s .  c  om
public class Main {

  public static void main(String[] args) {

    DataFlavor df = DataFlavor.stringFlavor;

    try {
      System.out.println (df.clone());
    } catch (CloneNotSupportedException e) {
      e.printStackTrace();
    }
  }
}




















Home »
  Java Tutorial »
    java.awt.datatransfer »




Clipboard
ClipboardOwner
DataFlavor
Transferable