Util.basename

Warning g_basename has been deprecated since version 2.2 and should not be used in newly-written code. Use g_path_get_basename() instead, but notice that g_path_get_basename() allocates new memory for the returned string, unlike this function which returns a pointer into the argument. Gets the name of the file without any leading directory components. It returns a pointer into the given file name string.

class Util
static
string
basename
(
string fileName
)

Parameters

fileName string

the name of the file.

Return Value

Type: string

the name of the file without any leading directory components.

Meta