node.js中的fs.linkSync方法使用说明
2023-06-13 09:15:33 时间
方法说明:
语法:
fs.linkSync(srcpath,dstpath)
由于该方法属于fs模块,使用前需要引入fs模块(varfs=require(“fs”))
接收参数:
srcpath 为源目录或文件的路径
dstpath 它是存放转换后的目录的路径,默认为当前工作目录
源码:
fs.linkSync=function(srcpath,dstpath){
nullCheck(srcpath);
nullCheck(dstpath);
returnbinding.link(pathModule._makeLong(srcpath),
pathModule._makeLong(dstpath));
};
相关文章
- js获取元素到文档区域document的(横向、纵向)坐标的两种方法
- JS toString()方法:返回一个对象的字符串
- JS定时器:setTimeout()和setInterval()方法
- JS getAttribute()方法:读取元素的属性值
- Node.js和MSSQL数据库的完美结合:使用node mssql模块(node mssql模块)
- JS调用CS里的带参方法实例
- 消除js以及jsp文件中的警告方法
- Node.js中安全调用系统命令的方法(避免注入安全漏洞)
- node.js中的events.emitter.removeListener方法使用说明
- node.js中的buffer.fill方法使用说明
- node.js中的fs.writeFile方法使用说明
- node.js中的fs.writeFileSync方法使用说明
- node.js中的fs.ftruncate方法使用说明
- node.js中的fs.unlinkSync方法使用说明
- node.js中的fs.truncateSync方法使用说明
- node.js中的fs.utimes方法使用说明
- node.js中的fs.renameSync方法使用说明
- node.js中的fs.readdir方法使用说明
- node.js中的fs.chmod方法使用说明
- node.js中的fs.chmodSync方法使用说明
- js中匿名函数的创建与调用方法分析
- 创建js对象和js类的方法汇总