Top Fields Constructors Methods
com.sun.glass.ui

public Class ClipboardAssistance

extends Object
Class Inheritance
Known Direct Subclasses
com.sun.javafx.tk.quantum.EmbeddedSceneDT.EmbeddedDTAssistant
Imports
java.util.HashMap

Field Summary

Modifier and TypeField and Description
private final HashMap<String, Object>
private final Clipboard
private int

Constructor Summary

AccessConstructor and Description
public
ClipboardAssistance(String
the clipboard name
cipboardName
)

Creates clipboard with mentioned name

Method Summary

Modifier and TypeMethod and Description
public void
actionPerformed(int
Clipboard.ACTION_COPY, or Clipboard.ACTION_MOVE, or Clipboard.ACTION_REFERENCE
action
)

Called by system and notifies about successful data transfer.

public void
close()

Close the notification channel

public void
contentChanged()

Called by system and notifies that data set in shared buffer were changed

public void
emptyCache()

Cleans the local cache.

public void
flush()

Synchronize prepared dataset with local/global clipboard content.

public Object

Returns:

the shared data object
getData
(String mimeType)

Returns the data from clipboard by mime type key.

public String[]
public int

Returns:

combination of Clipboard.ACTION_XXXX constants
getSupportedSourceActions
()

Gets the actions that are supported by source.

public boolean
public void
setData(String mimeType, Object data)

Fills the cache by a new (mime type, data) pair.

public void
setSupportedActions(int
combination of Clipboard.ACTION_XXXX constants
supportedActions
)

Sets the actions that are supported by source.

public void
setTargetAction(int
Clipboard.ACTION_COPY, or Clipboard.ACTION_MOVE, or Clipboard.ACTION_REFERENCE
actionDone
)

Sets the action that clipboard target performed of DnD target can.

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

cacheDataback to summary
private final HashMap<String, Object> cacheData
clipboardback to summary
private final Clipboard clipboard
supportedActionsback to summary
private int supportedActions

Constructor Detail

ClipboardAssistanceback to summary
public ClipboardAssistance(String cipboardName)

Creates clipboard with mentioned name

Parameters
cipboardName:String

the clipboard name

Method Detail

actionPerformedback to summary
public void actionPerformed(int action)

Called by system and notifies about successful data transfer. Delete-on-move functionality should be implemented here.

Parameters
action:int

Clipboard.ACTION_COPY, or Clipboard.ACTION_MOVE, or Clipboard.ACTION_REFERENCE

closeback to summary
public void close()

Close the notification channel

contentChangedback to summary
public void contentChanged()

Called by system and notifies that data set in shared buffer were changed

emptyCacheback to summary
public void emptyCache()

Cleans the local cache.

flushback to summary
public void flush()

Synchronize prepared dataset with local/global clipboard content. An application becomes the clipboard owner.

getDataback to summary
public Object getData(String mimeType)

Returns the data from clipboard by mime type key. That is always shared data.

Returns:Object

the shared data object

getMimeTypesback to summary
public String[] getMimeTypes()
getSupportedSourceActionsback to summary
public int getSupportedSourceActions()

Gets the actions that are supported by source.

Returns:int

combination of Clipboard.ACTION_XXXX constants

isCacheEmptyback to summary
public boolean isCacheEmpty()
setDataback to summary
public void setData(String mimeType, Object data)

Fills the cache by a new (mime type, data) pair. Performed by flush() call.

setSupportedActionsback to summary
public void setSupportedActions(int supportedActions)

Sets the actions that are supported by source. Performed by flush() call.

Parameters
supportedActions:int

combination of Clipboard.ACTION_XXXX constants

setTargetActionback to summary
public void setTargetAction(int actionDone)

Sets the action that clipboard target performed of DnD target can.

Parameters
actionDone:int

Clipboard.ACTION_COPY, or Clipboard.ACTION_MOVE, or Clipboard.ACTION_REFERENCE

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Annotations
@Override