开发者

GWT CSS Resource to find all classes

开发者 https://www.devze.com 2022-12-30 19:27 出处:网络
What i want to do is: I have css file read from a file into a String. I would like to build some kind of css resource (CssResource ?) out of that string or file, and I\'d like to be able to extract

What i want to do is:

I have css file read from a file into a String. I would like to build some kind of css resource (CssResource ?) out of that string or file, and I'd like to be able to extract from it all classes and id selectors in some kind of collection which开发者_开发问答 i could search.

Does anybody know how to do that ?


You need a CSS Parser. You can use a SAC compliant parser like CssParser. GWT internally uses a modified version of Flute. You could go with either of them, though I think CSSParser is better maintained.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号