Can someone help me parse from the C # method description: scope, isStatic, name, return type, and a list of parameters and their types. So, this method declaration like this
public static SomeReturnType GetSomething(string param1, int param2)
etc .. I need to analyze it and get the information above. So in this case
- name = "GetSomething"
- scope = "public"
- isStatic = true
- returnType = "SomeReturnType"
and then an array of parameter pairs and name pairs.
Oh, I almost forgot about the most important part. It should take into account all other areas (protected, private, internal, protected internal), the absence of a "static", invalid return type, etc.
Please note that REFLECTION is not a solution. I need a REGEX.
So far I have these two:
(?:(?:public)|(?:private)|(?:protected)|(?:internal)|(?:protected internal)\s+)*
(?:(?:static)\s+)*
, .