I remember reading somewhere, when using reflection and the overload of GetMethod
that accepts a bitmask of BindingFlags
, that BindingFlags.Default
is equivalent to BindingFlags.Public | BindingFlags.Static | BindingFlags.Instance
or something. Can anyone tell me what values are specifically included in BindingFlags.Default
? The MSDN documentation doesn't say, and I can't find the answer anywhere.
What is BindingFlags.Default equivalent to?
4.7k Views Asked by Big McLargeHuge At
2
There are 2 best solutions below
1

BindingFlags.Default specifies no binding flags. It is up to the user of the enumeration to choose what to do. System.Type.GetMethods() for example returns all public methods.
If you 'go to definition' on it, you'll see:
So, it looks like
BindingFlags.Default != BindingFlags.Public | BindingFlags.Static | BindingFlags.Instance
.