Cysharp / ConsoleAppFramework

Zero Dependency, Zero Overhead, Zero Reflection, Zero Allocation, AOT Safe CLI Framework powered by C# Source Generator.
MIT License
1.54k stars 88 forks source link

Added support for class inheritence for command classes #100

Closed riddlemd closed 1 month ago

riddlemd commented 1 year ago

Removed BindingFlags.DeclaredOnly from generic add methods and changed DeclaringType to ReflectedType in ConsoleAppEngine. This allows the use of command classes that inherit their commands form a parent class.

(last one I swear... pretty sure I tracked down all the bugs)

This update no longer hides the dispose methods, I recommend implicitly implementing the interface so they don't show up. It has a list of not allowed to inherit methods, but is implemented in a way that allows those methods to still show up in the console list if they're explicitly defined in the class for whatever reason (we don't check args, so you could have an Equals method for example that does something completely different than normal.)

github-actions[bot] commented 6 months ago

This PR is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 30 days.

riddlemd commented 6 months ago

Gonna die on the vine hu?

neuecc commented 6 months ago

sorry for delayed response, i'll check soon.

neuecc commented 1 month ago

sorry, we've moved to v5.

riddlemd commented 1 month ago

All good, does v5 support inheritance? If not I can start looking into adding it to that.