docs.unity3d.com
    Show / Hide Table of Contents

    Class PathUtility

    Inheritance
    Object
    PathUtility
    Namespace: Unity.VisualScripting
    Syntax
    public static class PathUtility

    Methods

    CreateDirectoryIfNeeded(String)

    Declaration
    public static void CreateDirectoryIfNeeded(string path)
    Parameters
    Type Name Description
    String path

    CreateParentDirectoryIfNeeded(String)

    Declaration
    public static void CreateParentDirectoryIfNeeded(string path)
    Parameters
    Type Name Description
    String path

    DeleteDirectoryIfExists(String)

    Declaration
    public static void DeleteDirectoryIfExists(string path)
    Parameters
    Type Name Description
    String path

    DeleteProjectFileIfExists(String, Boolean)

    Declaration
    public static void DeleteProjectFileIfExists(string filePath, bool checkoutInVersionControl = false)
    Parameters
    Type Name Description
    String filePath
    Boolean checkoutInVersionControl

    FromAssets(String)

    Declaration
    public static string FromAssets(string path)
    Parameters
    Type Name Description
    String path
    Returns
    Type Description
    String

    FromEditorResources(String)

    Declaration
    public static string FromEditorResources(string path)
    Parameters
    Type Name Description
    String path
    Returns
    Type Description
    String

    FromProject(String)

    Declaration
    public static string FromProject(string path)
    Parameters
    Type Name Description
    String path
    Returns
    Type Description
    String

    GetPackageRootPath()

    Declaration
    public static string GetPackageRootPath()
    Returns
    Type Description
    String

    GetRelativePath(String, String)

    Declaration
    public static string GetRelativePath(string path, string directory)
    Parameters
    Type Name Description
    String path
    String directory
    Returns
    Type Description
    String

    MakeSafeFilename(String, Char)

    Declaration
    public static string MakeSafeFilename(string filename, char replace)
    Parameters
    Type Name Description
    String filename
    Char replace
    Returns
    Type Description
    String

    TryPathsForFile(String, IEnumerable<String>)

    Declaration
    public static string TryPathsForFile(string fileName, IEnumerable<string> directories)
    Parameters
    Type Name Description
    String fileName
    IEnumerable<String> directories
    Returns
    Type Description
    String

    TryPathsForFile(String, String[])

    Declaration
    public static string TryPathsForFile(string fileName, params string[] directories)
    Parameters
    Type Name Description
    String fileName
    String[] directories
    Returns
    Type Description
    String
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023