Drag[en]gine Script Module DragonScript
1.21
|
Clipboard clip storing data in multiple formats. More...
Public Member Functions | |
Array | collect (Block ablock) |
Collect data with block receiving object as argument returning true to include. More... | |
Array | collectCastable (Block ablock) |
Collect data with block receiving object as argument returning true to include. More... | |
Object | find (Block ablock) |
Find data with block receiving object as argument returning true if found. More... | |
Object | findCastable (Block ablock) |
Find data with block receiving object as argument returning true if found. More... | |
void | forEach (Block ablock) |
Visit data with block receiving object as argument. More... | |
void | forEachCastable (Block ablock) |
Visit data with block receiving object as argument. More... | |
Object | getAt (int index) |
Data at index. More... | |
int | getCount () |
Count of data. More... | |
Object | last () |
Last data. More... | |
ClipboardClip | new (Array data) |
Create clipboard clip with data. More... | |
Clipboard clip storing data in multiple formats.
Data is added in the order of the most specific object class to the most generic. Adding String as last entry for non-String objects is not required since the clip consumer has to call toString() on the last data entry if he wants to consume any type of object as string.
Immutable class.
Array Dragengine.Gui.ClipboardClip.collect | ( | Block | ablock | ) |
Collect data with block receiving object as argument returning true to include.
Returns Array containing all objects for which block returns true.
Array Dragengine.Gui.ClipboardClip.collectCastable | ( | Block | ablock | ) |
Collect data with block receiving object as argument returning true to include.
Returns Array containing all objects for which block returns true. Block is called only for objects castable to block argument.
Object Dragengine.Gui.ClipboardClip.find | ( | Block | ablock | ) |
Find data with block receiving object as argument returning true if found.
Returns first object for which block returns true or null.
Object Dragengine.Gui.ClipboardClip.findCastable | ( | Block | ablock | ) |
Find data with block receiving object as argument returning true if found.
Returns first object for which block returns true or null. Block is called only for objects castable to block argument.
void Dragengine.Gui.ClipboardClip.forEach | ( | Block | ablock | ) |
Visit data with block receiving object as argument.
void Dragengine.Gui.ClipboardClip.forEachCastable | ( | Block | ablock | ) |
Visit data with block receiving object as argument.
Block is only called for objects castable to block argument.
Object Dragengine.Gui.ClipboardClip.getAt | ( | int | index | ) |
Data at index.
int Dragengine.Gui.ClipboardClip.getCount | ( | ) |
Count of data.
Object Dragengine.Gui.ClipboardClip.last | ( | ) |
Last data.
ClipboardClip Dragengine.Gui.ClipboardClip.new | ( | Array | data | ) |
Create clipboard clip with data.
ENullPointer | data or entry in data is null. |
EInvalidParam | data is empty. |