I have this string with me.
class a : public b, public c, public d { (class syntax in C++)
Now i want to get all baseclass names in one single variable through regex in C#.
I am getting derived class name properly, but getting base class name is the issue.
I have developed this regex :
@"((class|interface)\s*?(?
Can anyone help me in the same?
kiran kiranPosted Oct 16, 2009, 6:15 AM
string StrClass = "class DerivedClass2 : public BaseClass1, public BaseClass2, public BaseClass3 { ";
string RegexClass = @"((class|interface)(\s*?|\n*?)(?
m = Regex.Match(StrClass, RegexClass, RegexOptions.RightToLeft);
string OutputClass = m.Result("${classname}");
string OutputBaseClass = m.Result("${baseclassname}");
Master BillaPosted Oct 16, 2009, 4:39 AM
Could you post your code here?
thnx