@ccms/nodejs
Version:
MiaoScript nodejs package
100 lines • 2.9 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.copyFileSync = exports.accessSync = exports.existsSync = exports.unwatchFile = exports.watchFile = exports.appendFileSync = exports.writeFileSync = exports.readFileSync = exports.readdirSync = exports.mkdtempSync = exports.mkdirSync = exports.rmdirSync = exports.unlinkSync = exports.realpathSync = exports.readlinkSync = exports.symlinkSync = exports.statSync = exports.chmodSync = exports.chownSync = exports.truncateSync = exports.renameSync = void 0;
require("@ccms/nashorn");
var Path = Java.type("java.nio.file.Path");
var JavaString = Java.type("java.lang.String");
var File = Java.type("java.io.File");
var Files = Java.type("java.nio.file.Files");
var Collector = Java.type("java.util.stream.Collector");
var separatorChar = File.separatorChar;
var StandardCopyOption = Java.type("java.nio.file.StandardCopyOption");
function javaFile() {
var opts = [];
for (var _i = 0; _i < arguments.length; _i++) {
opts[_i] = arguments[_i];
}
if (!opts[0]) {
console.warn("文件名称不得为 undefined 或者 null !");
}
switch (opts.length) {
case 1:
var f = opts[0];
if (f instanceof File) {
return f;
}
if (typeof f === "string") {
return new File(f);
}
if (f instanceof Path) {
return f.toFile();
}
break;
default:
return new File(javaFile(opts[0]), opts[1]);
}
}
function renameSync(oldPath, newPath) {
}
exports.renameSync = renameSync;
function truncateSync() {
}
exports.truncateSync = truncateSync;
function chownSync() {
}
exports.chownSync = chownSync;
function chmodSync() {
}
exports.chmodSync = chmodSync;
function statSync() {
}
exports.statSync = statSync;
function symlinkSync() {
}
exports.symlinkSync = symlinkSync;
function readlinkSync() {
}
exports.readlinkSync = readlinkSync;
function realpathSync() {
}
exports.realpathSync = realpathSync;
function unlinkSync() {
}
exports.unlinkSync = unlinkSync;
function rmdirSync() {
}
exports.rmdirSync = rmdirSync;
function mkdirSync() {
}
exports.mkdirSync = mkdirSync;
function mkdtempSync() {
}
exports.mkdtempSync = mkdtempSync;
function readdirSync() {
}
exports.readdirSync = readdirSync;
function readFileSync() {
}
exports.readFileSync = readFileSync;
function writeFileSync() {
}
exports.writeFileSync = writeFileSync;
function appendFileSync() {
}
exports.appendFileSync = appendFileSync;
function watchFile() {
}
exports.watchFile = watchFile;
function unwatchFile() {
}
exports.unwatchFile = unwatchFile;
function existsSync() {
}
exports.existsSync = existsSync;
function accessSync() {
}
exports.accessSync = accessSync;
function copyFileSync() {
}
exports.copyFileSync = copyFileSync;
//# sourceMappingURL=index.js.map