/** * Assigns terms from declaration * * @param d * Declaration which contains terms */ public void assignTermsFromDeclaration(Declaration d) { this.terms = d.asList(); }
/** * Assigns terms from declaration * * @param d * Declaration which contains terms */ public void assignTermsFromDeclaration(Declaration d) { this.terms = d.asList(); }
/** * Assigns terms from declaration * * @param d * Declaration which contains terms */ public void assignTermsFromDeclaration(Declaration d) { this.terms = d.asList(); }
/** * Assigns terms from declaration * * @param d * Declaration which contains terms */ public void assignTermsFromDeclaration(Declaration d) { this.terms = d.asList(); }
/** * Shallow copy constructor * @param clone Declaration to share term values with */ protected DeclarationImpl(Declaration clone) { this.property = clone.getProperty(); this.important = clone.isImportant(); this.replaceAll(clone.asList()); }
for (Term<?> t : d.asList()) { if (t instanceof TermFunction && validFuncNames.contains(((TermFunction) t)
@SuppressWarnings("unused") private boolean processTransform(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { // just a simple value (e.g. "none") if (d.size() == 1 && genericOneIdent(Transform.class, d, properties)) { return true; } else { TermList list = tf.createList(); for (Term<?> t : d.asList()) { if (t instanceof TermFunction.TransformFunction) list.add(t); else return false; } // there is nothing in list after parsing if (list.isEmpty()) return false; properties.put("transform", Transform.list_values); values.put("transform", list); return true; } }
/** * Shallow copy constructor * @param clone Declaration to share term values with */ protected DeclarationImpl(Declaration clone) { this.property = clone.getProperty(); this.important = clone.isImportant(); this.source = new Source(clone.getSource()); this.replaceAll(clone.asList()); }
/** * Shallow copy constructor * @param clone Declaration to share term values with */ protected DeclarationImpl(Declaration clone) { this.property = clone.getProperty(); this.important = clone.isImportant(); this.source = new Source(clone.getSource()); this.replaceAll(clone.asList()); }
/** * Shallow copy constructor * @param clone Declaration to share term values with */ protected DeclarationImpl(Declaration clone) { this.property = clone.getProperty(); this.important = clone.isImportant(); this.source = new Source(clone.getSource()); this.replaceAll(clone.asList()); }
@SuppressWarnings("unused") private boolean processBackdropFilter(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { // single ident: none, or global ones if (d.size() == 1 && genericOneIdent(BackdropFilter.class, d, properties)) { return true; } else { //list of uri() or <filter-function> expected TermList list = tf.createList(); for (Term<?> t : d.asList()) { if (t instanceof TermFunction.FilterFunction) list.add(t); else if (t instanceof TermURI) list.add(t); else return false; } // there is nothing in list after parsing if (list.isEmpty()) return false; properties.put("backdrop-filter", BackdropFilter.list_values); values.put("backdrop-filter", list); return true; } }
TermList list = tf.createList(); TextDecoration dec = null; for (Term<?> term : d.asList()) { if (term instanceof TermIdent && (dec = genericPropertyRaw(TextDecoration.class,
@SuppressWarnings("unused") private boolean processFilter(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { // single ident: none, or global ones if (d.size() == 1 && genericOneIdent(Filter.class, d, properties)) { return true; } else { //list of uri() or <filter-function> expected TermList list = tf.createList(); for (Term<?> t : d.asList()) { if (t instanceof TermFunction.FilterFunction) list.add(t); else if (t instanceof TermURI) list.add(t); else return false; } // there is nothing in list after parsing if (list.isEmpty()) return false; properties.put("filter", Filter.list_values); values.put("filter", list); return true; } }
@SuppressWarnings("unused") private boolean processQuotes(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { if (d.size() == 1 && genericTermIdent(Quotes.class, d.get(0), ALLOW_INH, "quotes", properties)) { return true; } else { TermList list = tf.createList(); for (Term<?> term : d.asList()) { if (term instanceof TermString) list.add(term); else return false; } // there are pairs of quotes if (!list.isEmpty() && list.size() % 2 == 0) { properties.put("quotes", Quotes.list_values); values.put("quotes", list); return true; } return false; } }
@SuppressWarnings("unused") private boolean processQuotes(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { if (d.size() == 1 && genericTermIdent(Quotes.class, d.get(0), ALLOW_INH, "quotes", properties)) { return true; } else { TermList list = tf.createList(); for (Term<?> term : d.asList()) { if (term instanceof TermString) list.add(term); else return false; } // there are pairs of quotes if (!list.isEmpty() && list.size() % 2 == 0) { properties.put("quotes", Quotes.list_values); values.put("quotes", list); return true; } return false; } }
@SuppressWarnings("unused") private boolean processQuotes(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { if (d.size() == 1 && genericTermIdent(Quotes.class, d.get(0), ALLOW_INH, "quotes", properties)) { return true; } else { TermList list = tf.createList(); for (Term<?> term : d.asList()) { if (term instanceof TermString) list.add(term); else return false; } // there are pairs of quotes if (!list.isEmpty() && list.size() % 2 == 0) { properties.put("quotes", Quotes.list_values); values.put("quotes", list); return true; } return false; } }
@SuppressWarnings("unused") private boolean processQuotes(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { if (d.size() == 1 && genericTermIdent(Quotes.class, d.get(0), ALLOW_INH, "quotes", properties)) { return true; } else { TermList list = tf.createList(); for (Term<?> term : d.asList()) { if (term instanceof TermString) list.add(term); else return false; } // there are pairs of quotes if (!list.isEmpty() && list.size() % 2 == 0) { properties.put("quotes", Quotes.list_values); values.put("quotes", list); return true; } return false; } }
for (Term<?> term : d.asList()) { if (term instanceof TermURI) { list.add(term);
for (Term<?> term : d.asList()) { if (term instanceof TermURI) { list.add(term);
for (Term<?> term : d.asList()) { if (term instanceof TermURI) { list.add(term);