NDepend.Path icon indicating copy to clipboard operation
NDepend.Path copied to clipboard

Feature Suggestions

Open mikernet opened this issue 7 years ago • 1 comments

I love this library, but here are a couple things I've run into that I think would make it better:

  • relative path interfaces should have a parameterless GetAbsolutePath() method that gets an absolute path relative to the working directory, which is a pretty common operation

  • FileInfo / DirectoryInfo properties can be cache the created instance on the first get call and return that for subsequent calls instead of making a new instance each time


Any interest in having these items added? I could assist with implementing them.

Unrelated aside: I would have much preferred if you could use this library without the string extensions, but rather with methods like: DirectoryPath.Create(string path), AbsoluteDirectoryPath.Create(string path) etc...or just using constructors. It feels like a bad code smell to pollute the string class with methods that only apply to paths and not to any other strings.

mikernet avatar Nov 09 '17 20:11 mikernet

Please feel free to improve this lib. So far this lib fits perfectly our needs and it is bug free as far as we know (from millions of logged usages in prod) so it is stable and we are not investing more dev in it.

Concerning the string extensions, they apply only in source file where you have using NDepend.Path, so this limits a lot the problem you describe, and we like the ctor-less extension method extension (I guess it is a matter of habits).

ndepend avatar Nov 10 '17 04:11 ndepend