/** * Creates the analyzer for a single style sheet. * @param sheet The stylesheet that will be used as the source of rules. */ public Analyzer(StyleSheet sheet) { this.rules = Collections.synchronizedMap(new HashMap<String, Holder>()); classifyRules(sheet); }
/** * Creates the analyzer for multiple style sheets. * @param sheets A list of stylesheets that will be used as the source of rules. */ public Analyzer(List<StyleSheet> sheets) { this.rules = Collections.synchronizedMap(new HashMap<String, Holder>()); for (StyleSheet sheet : sheets) classifyRules(sheet); }
/** * Classifies the rules in all the style sheets. * @param mediaspec The specification of the media for evaluating the media queries. */ protected void classifyAllSheets(MediaSpec mediaspec) { rules = new Holder(); for (StyleSheet sheet : sheets) classifyRules(sheet, mediaspec); }