This method returns the EE stream at the given index and format. This method will
return null if data is not found.
function onPaste()
{
var clipboard = shell.clipboard;
if (clipboard)
{
if (clipboard.hasFormat("PNG"))
{
var png = clipboard.getStreamAt(0, "PNG");
if (png)
{
// Do something.
}
}
}
}