path.dirname

path.dirname

path.dirname

功能

返回父目录路径。

语法

参数

无。

返回值

类型说明
String父目录路径;没有父目录时返回空字符串。

代码示例

注意事项

  • 不访问文件系统。