anysort | Sorting utility using configurable string glob | Regex library
kandi X-RAY | anysort Summary
kandi X-RAY | anysort Summary
anysort
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of anysort
anysort Key Features
anysort Examples and Code Snippets
Community Discussions
Trending Discussions on anysort
QUESTION
I'm looking for a way to make my code shorter. Since a big part of my code is repeatable, is there any way to pass a sub method name as a parmeter?
Here is a some bigger part to make my problem some more clear:
...ANSWER
Answered 2017-May-22 at 18:42If you're trying to pass in a reference to your sort method instead of hard-coding it, then yes, you can have this method take in a delegate (function pointer) to your sort method:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install anysort
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page