reflection – C# – Resolving a parameter name at runtime – Stack Overflow
Posted by jpluimers on 2012/03/27
So I won’t forget: a GetName method returning the name of a parameter, local or field.
Tags: C#, reflection, IL parsing, argument name, anonymous type, generic type cache, generic type caching.
–jeroen
via: reflection – C# – Resolving a parameter name at runtime – Stack Overflow.
.NET/C#: Getting volume free space from UNC path requires PInvoke of GetDiskFreeSpaceEx in Kernel32.dll « The Wiert Corner – irregular stream of stuff said
[…] the use of GetDiskFreeSpaceEx that generates CSV output for the passed parameters. It uses the anonymous type cache, and below is the code I promised a while […]
.net/C#: you can pass anoymous types to a generic method, but not return them as a method result « The Wiert Corner – irregular stream of stuff said
[…] anonymous types to a method, if that method has a generic parameter type. I regularly use this to Resolving a parameter name at runtime using the Generic Type Cache technique described by Rinat […]
Getting the public static readonly strings and public const strings (and their values) from a class - .NET Code Geeks said
[…] public const fields. Not flexible enough. There are a few tricks used. The first trick is how to obtain the name of a method parameter without using a string literal (you now probably get it that I don’t like literals). Thanks to Rinat Abdullin, he provided […]
Getting the public static readonly strings and public const strings (and their values) from a class « The Wiert Corner – irregular stream of Wiert stuff said
[…] first trick is how to obtain the name of a method parameter without using a string literal (you now probably get it that I don’t like literals). Thanks to Rinat Abdullin, he provided […]