View source code
Display the source code in dmd/root/filename.d from which this
page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a
Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page.
Requires a signed-in GitHub account. This works well for small changes.
If you'd like to make larger changes you may want to consider using
local clone.
Struct dmd.root.filename.FileName
Encapsulate path and file names.
struct FileName
;
Constructors
Name | Description |
---|---|
this
|
Methods
Name | Description |
---|---|
absolute
|
Determine if path is absolute. |
addExt
|
Add the extension ext to name , regardless of the content of name
|
canonicalName
|
Return canonical version of name in a malloc'd buffer. This code is high risk. |
combine
|
Combine a path and a file name
|
defaultExt
|
Free returned value with FileName::free() |
ensurePathExists
|
Ensure that the provided path exists |
equals
|
Compare two name according to the platform's rules (case sensitive or not) |
equalsExt
|
|
equalsExt
|
Return !=0 if extensions match. |
exists
|
Check if the file the path points to exists
|
ext
|
Determine file name extension as slice of input. |
forceExt
|
Free returned value with FileName::free() |
free
|
Free memory allocated by FileName routines |
name
|
Return filename name excluding path (read-only). |
path
|
Return path portion of str. Path will does not include trailing path separator. |
removeExt
|
Return file name without extension. |
replaceName
|
Replace filename portion of path. |
safeSearchPath
|
Search Path for file in a safe manner. |
searchPath
|
Search Path for file. |
toAbsolute
|
Return the given name as an absolute path |
Authors
Walter Bright, http://www.digitalmars.com
License
Copyright © 1999-2022 by the D Language Foundation | Page generated by ddox.