pulsar/native/v8_extensions/native.js

80 lines
1.8 KiB
JavaScript
Raw Normal View History

2012-08-27 22:37:06 +04:00
var $native = {};
(function() {
native function exists(path);
$native.exists = exists;
native function read(path);
$native.read = read;
native function write(path, content);
$native.write = write;
native function absolute(path);
$native.absolute = absolute;
2012-10-09 11:28:28 +04:00
native function traverseTree(path, onFile, onDirectory);
2012-10-09 07:17:09 +04:00
$native.traverseTree = traverseTree;
2012-12-13 05:25:45 +04:00
native function getAllFilePathsAsync(path, callback);
$native.getAllFilePathsAsync = getAllFilePathsAsync;
2012-12-13 00:26:39 +04:00
2012-08-27 22:37:06 +04:00
native function isFile(path);
$native.isFile = isFile;
native function isDirectory(path);
$native.isDirectory = isDirectory;
native function remove(path);
$native.remove = remove;
native function open(path);
$native.open = open;
native function quit();
$native.quit = quit;
native function writeToPasteboard(text);
$native.writeToPasteboard = writeToPasteboard;
native function readFromPasteboard();
$native.readFromPasteboard = readFromPasteboard;
native function watchPath(path);
$native.watchPath = watchPath;
native function unwatchPath(path, callbackId);
$native.unwatchPath = unwatchPath;
native function getWatchedPaths();
$native.getWatchedPaths = getWatchedPaths;
2012-11-30 03:31:05 +04:00
native function unwatchAllPaths();
$native.unwatchAllPaths = unwatchAllPaths;
2012-08-27 22:37:06 +04:00
native function makeDirectory(path);
$native.makeDirectory = makeDirectory;
native function move(sourcePath, targetPath);
$native.move = move;
native function moveToTrash(path);
$native.moveToTrash = moveToTrash;
native function reload();
$native.reload = reload;
native function lastModified(path);
$native.lastModified = lastModified;
native function md5ForPath(path);
$native.md5ForPath = md5ForPath;
native function exec(command, options, callback);
$native.exec = exec;
native function getPlatform();
$native.getPlatform = getPlatform;
})();