HDK
|
#include <UT_PathSearch.h>
Classes | |
struct | CommonPaths |
Public Member Functions | |
UT_PathSearch (const char *defpath, int var_id, const char *carat_expand="", int at_expand=UT_HOUDINI_PATH) | |
UT_PathSearch (const UT_PathSearch ©)=default | |
void | rehash () |
void | extendPath (const char *defpath=0, int var_id=-1, const char *carat_expand=0, int at_expand=-1) |
bool | appendPath (const char *path, bool condensed=false) |
bool | removePath (const char *path) |
bool | prependPath (const char *path, bool condensed=false) |
int | findFile (UT_String &result, const char *search) const |
int | findFile (UT_WorkBuffer &result, const char *search) const |
int | findDirectory (UT_String &result, const char *search) const |
bool | findFileFromList (UT_String &result, const UT_StringArray &search_list) const |
bool | findDirectoryFromList (UT_String &result, const UT_StringArray &search_list) const |
int | findAllFiles (const char *search, UT_StringArray &list) const |
int | findAllDirectories (const char *search, UT_StringArray &list) const |
int | matchAllFiles (const char *extension, bool returnfullpaths, UT_StringArray &list, bool recurse=false, bool skip_dup_paths=false) const |
int | matchAllFiles (const UT_StringList &exts, bool returnfullpaths, UT_StringArray &list, bool recurse=false, bool skip_dup_paths=false) const |
int | matchAllFilesInSubdirectory (const char *extension, const char *subdirectory, bool returnfullpaths, UT_StringArray &list, bool recurse=false, bool skip_dup_paths=false) const |
int | matchAllFilesInSubdirectory (const UT_StringList &exts, const char *subdirectory, bool returnfullpaths, UT_StringArray &list, bool recurse=false, bool skip_dup_paths=false) const |
int | houdiniFindFile (const char *find, UT_String &result) const |
int | houdiniFindFile (const char *find, UT_WorkBuffer &result) const |
int | houdiniFindDirectory (const char *find, UT_String &result) const |
int | houdiniFindDirectory (const char *find, UT_WorkBuffer &r) const |
int | getEntries () const |
const char * | getPathComponent (int i) const |
int | getBaseEntries () const |
const char * | getBaseComponent (int i) const |
const char * | getCondensedComponent (int i) const |
const char * | getDefaultPath () const |
const char * | getCaratExpand () const |
int | getVariableId () const |
int | getAtExpand () const |
void | getHomeHoudiniSearch (UT_StringArray &strs) const |
Static Public Member Functions | |
static bool | pathMap (UT_String &path) |
static bool | pathMap (UT_StringHolder &result, const char *path) |
static void | pathMapSave (UT_WorkBuffer &wbuf, bool pretty) |
static void | pathMapLoad (const char *dict) |
static void | pathMapAdd (const char *src, const char *dest, bool case_sensitive) |
static bool | pathMapRemove (const char *src) |
static UT_KnownPath | lookupPath (const char *name) |
static const char * | lookupPath (UT_KnownPath path) |
static const UT_PathSearch * | getInstance (UT_KnownPath path_type) |
static UT_PathSearch * | getHardPath (UT_KnownPath path_type) |
static void | rehashAll () |
static void | rehashSpecific (UT_KnownPath pathid) |
static int | condenseHip (UT_String &path) |
static int | condenseHip (UT_WorkBuffer &path) |
static int | condenseJob (UT_String &path) |
static bool | condensePath (UT_WorkBuffer &result, const char *source_path, const char *const paths[], const char *const condensed_paths[], int npaths) |
static bool | condensePath (UT_String &path, const char *source_path, const char *const paths[], const char *const condensed_paths[], int npaths) |
static bool | condensePath (UT_String &path, const char *const paths[], const char *const condensed_paths[], int npaths) |
static int | stripLeadPath (UT_String &path, UT_KnownPath pathvar) |
static int | stripMaxLeadPath (UT_String &path, UT_KnownPath pathvar) |
static bool | resolveAbsolutePath (const char *filename, UT_String &absolute_path) |
static void | splitPath (const char *path, UT_StringArray &list, const char *insert_path) |
static void | getHomeHoudini (UT_String &str) |
static SYS_NO_DISCARD_RESULT UT_StringHolder | getHomeHoudini () |
static bool | condenseCommon (UT_String &path) |
static bool | condenseCommon (UT_WorkBuffer &path) |
static bool | condenseCommon (UT_String &condensed, const char *path) |
static bool | condenseCommon (UT_WorkBuffer &condensed, const char *path) |
static bool | condenseCommon (UT_String &path, const CommonPaths &common) |
static bool | condenseCommon (UT_WorkBuffer &path, const CommonPaths &common) |
static bool | condenseCommon (UT_String &path, const char *source_path, const CommonPaths &common) |
static bool | condenseCommon (UT_WorkBuffer &path, const char *source_path, const CommonPaths &common) |
Definition at line 54 of file UT_PathSearch.h.
UT_PathSearch::UT_PathSearch | ( | const char * | defpath, |
int | var_id, | ||
const char * | carat_expand = "" , |
||
int | at_expand = UT_HOUDINI_PATH |
||
) |
|
default |
bool UT_PathSearch::appendPath | ( | const char * | path, |
bool | condensed = false |
||
) |
|
inlinestatic |
Definition at line 233 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 243 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 253 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 263 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 270 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 276 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 282 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 290 of file UT_PathSearch.h.
|
static |
|
static |
|
inlinestatic |
Definition at line 309 of file UT_PathSearch.h.
|
inlinestatic |
Definition at line 326 of file UT_PathSearch.h.
void UT_PathSearch::extendPath | ( | const char * | defpath = 0 , |
int | var_id = -1 , |
||
const char * | carat_expand = 0 , |
||
int | at_expand = -1 |
||
) |
int UT_PathSearch::findAllDirectories | ( | const char * | search, |
UT_StringArray & | list | ||
) | const |
int UT_PathSearch::findAllFiles | ( | const char * | search, |
UT_StringArray & | list | ||
) | const |
bool UT_PathSearch::findDirectoryFromList | ( | UT_String & | result, |
const UT_StringArray & | search_list | ||
) | const |
int UT_PathSearch::findFile | ( | UT_WorkBuffer & | result, |
const char * | search | ||
) | const |
bool UT_PathSearch::findFileFromList | ( | UT_String & | result, |
const UT_StringArray & | search_list | ||
) | const |
|
inline |
Definition at line 202 of file UT_PathSearch.h.
|
inline |
Definition at line 194 of file UT_PathSearch.h.
|
inline |
Definition at line 193 of file UT_PathSearch.h.
|
inline |
Definition at line 199 of file UT_PathSearch.h.
|
inline |
Definition at line 195 of file UT_PathSearch.h.
|
inline |
Definition at line 198 of file UT_PathSearch.h.
|
inline |
Definition at line 188 of file UT_PathSearch.h.
|
static |
|
static |
void UT_PathSearch::getHomeHoudiniSearch | ( | UT_StringArray & | strs | ) | const |
|
static |
|
inline |
Definition at line 189 of file UT_PathSearch.h.
|
inline |
Definition at line 201 of file UT_PathSearch.h.
int UT_PathSearch::houdiniFindDirectory | ( | const char * | find, |
UT_WorkBuffer & | r | ||
) | const |
int UT_PathSearch::houdiniFindFile | ( | const char * | find, |
UT_WorkBuffer & | result | ||
) | const |
|
static |
Given a variable name (e.g. "HOUDINI_PATH") return the known path enum associated with it. If the name doesn't match a known path, the function will return UT_MAX_KNOWN_PATHS
.
|
static |
Given a known path, return the variable name associated with the path Returns nullptr
on error.
int UT_PathSearch::matchAllFiles | ( | const char * | extension, |
bool | returnfullpaths, | ||
UT_StringArray & | list, | ||
bool | recurse = false , |
||
bool | skip_dup_paths = false |
||
) | const |
int UT_PathSearch::matchAllFiles | ( | const UT_StringList & | exts, |
bool | returnfullpaths, | ||
UT_StringArray & | list, | ||
bool | recurse = false , |
||
bool | skip_dup_paths = false |
||
) | const |
int UT_PathSearch::matchAllFilesInSubdirectory | ( | const char * | extension, |
const char * | subdirectory, | ||
bool | returnfullpaths, | ||
UT_StringArray & | list, | ||
bool | recurse = false , |
||
bool | skip_dup_paths = false |
||
) | const |
int UT_PathSearch::matchAllFilesInSubdirectory | ( | const UT_StringList & | exts, |
const char * | subdirectory, | ||
bool | returnfullpaths, | ||
UT_StringArray & | list, | ||
bool | recurse = false , |
||
bool | skip_dup_paths = false |
||
) | const |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
bool UT_PathSearch::prependPath | ( | const char * | path, |
bool | condensed = false |
||
) |
void UT_PathSearch::rehash | ( | ) |
|
static |
|
static |
bool UT_PathSearch::removePath | ( | const char * | path | ) |
|
static |
|
static |
|
static |
|
static |