大家好,我是提高图书馆正则表达式的新手.对我来说,它有点复杂.我需要将字词格式分开. 格式为 尊敬的客户{Customer.Customer_Id:D}报价{Offer.Offer_Id:D}发件人.... 我需要将所有单词和{Customer.Customer_Id:D}分开作为单独的单词,并且过程一直进行到最后一个单词出现为止. 我已尽力而为,但我无法解析上述格式的通用表达式 如果你知道的话告诉我... 在此先感谢 ganesh_IT
Hi guys, i am new to boost libraries regular expression.for me its something complicated.I need to separate word form my format. The format is Dear customer {Customer.Customer_Id:D} offer {Offer.Offer_Id:D} From.... i need to separate all words and {Customer.Customer_Id:D} as a separate word and process is going on until the last word occurs. I try my best but i cant get the general expression for parsing the above format If you know tell me guys... Thanks in advance ganesh_IT
推荐答案尚不清楚,但似乎您想将{Customer.Customer_Id:D},{Offer.Offer_Id:D}与格式字符串分开. 如果是这样,以下表达将帮助您到达那里. It is not much clear, but seems like you want to separate {Customer.Customer_Id:D}, {Offer.Offer_Id:D} from your format string. If so, following expression will help you get there. {[^\s]+}
如果您不希望{},则可以捕获组
If you don''t want {} then capture groups
{([^\s]+)}
更多推荐
促进正则表达式问题
发布评论