Provides utility functions for filenames.
FileInfo provides easy access to the components of a file's path
relative to the project root.
Definition at line 1250 of file iodaconv_cpplint.py.
◆ __init__()
def iodaconv_cpplint.FileInfo.__init__ |
( |
|
self, |
|
|
|
filename |
|
) |
| |
◆ BaseName()
def iodaconv_cpplint.FileInfo.BaseName |
( |
|
self | ) |
|
File base name - text after the final slash, before the final period.
Definition at line 1339 of file iodaconv_cpplint.py.
◆ Extension()
def iodaconv_cpplint.FileInfo.Extension |
( |
|
self | ) |
|
File extension - text following the final period, includes that period.
Definition at line 1343 of file iodaconv_cpplint.py.
◆ FullName()
def iodaconv_cpplint.FileInfo.FullName |
( |
|
self | ) |
|
◆ IsSource()
def iodaconv_cpplint.FileInfo.IsSource |
( |
|
self | ) |
|
◆ NoExtension()
def iodaconv_cpplint.FileInfo.NoExtension |
( |
|
self | ) |
|
◆ RepositoryName()
def iodaconv_cpplint.FileInfo.RepositoryName |
( |
|
self | ) |
|
FullName after removing the local path to the repository.
If we have a real absolute path name here we can try to do something smart:
detecting the root of the checkout and truncating /path/to/checkout from
the name so that we get header guards that don't include things like
"C:\Documents and Settings\..." or "/home/username/..." in them and thus
people on different computers who have checked the source out to different
locations won't see bogus errors.
Definition at line 1264 of file iodaconv_cpplint.py.
◆ Split()
def iodaconv_cpplint.FileInfo.Split |
( |
|
self | ) |
|
Splits the file into the directory, basename, and extension.
For 'chrome/browser/browser.cc', Split() would
return ('chrome/browser', 'browser', '.cc')
Returns:
A tuple of (directory, basename, extension).
Definition at line 1325 of file iodaconv_cpplint.py.
◆ _filename
iodaconv_cpplint.FileInfo._filename |
|
private |
The documentation for this class was generated from the following file: