c# - create a regular expression of a specific sentence -


i using constraint file system , using line parsing values:

angle(vector(jointa,jointb),vector(jointa,jointb),minvalue,maxvalue)

can please me , specify regular expression of line. want able retrieve names of 4 joints, including minvalue maxvalue. thanks!

if you're asking way parse variable bits kind of text, it's quite easy:

see here: http://tinyurl.com/qjdaj9w

var exp = new regex(@"angle\(vector\((.*?),(.*?)\),vector\((.*?),(.*?)\),(.*?),(.*?)\)");  var match = exp.match("angle(vector(jointa,jointb),vector(jointa,jointb),minvalue,maxvalue)");   var jointa1 = match.groups[0]; var jointb1 = match.groups[1]; var jointa2 = match.groups[2]; var jointb2 = match.groups[3]; var max     = match.groups[4]; var min     = match.groups[5]; 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -