public void error(CSSParseException exception) throws CSSException { if (!ignore(exception)) { defaultHandler.error(exception); } }
public void error(CSSParseException exception) throws CSSException { if (!ignore(exception)) defaultHandler.error(exception); }
public void error(CSSParseException exception) throws CSSException { if (!ignore(exception)) defaultHandler.error(exception); }
public void parseStyleDeclaration(final InputSource source) throws IOException { source_ = source; ReInit(getCharStream(source)); try { styleDeclaration(); } catch (final ParseException e) { getErrorHandler().error(toCSSParseException("invalidStyleDeclaration", e)); } catch (final TokenMgrError e) { getErrorHandler().error(toCSSParseException(e)); } catch (final CSSParseException e) { getErrorHandler().error(e); } }
public SelectorList parseSelectors(final InputSource source) throws IOException { source_ = source; ReInit(getCharStream(source)); SelectorList sl = null; try { sl = parseSelectorsInternal(); } catch (final ParseException e) { getErrorHandler().error(toCSSParseException("invalidSelectorList", e)); } catch (final TokenMgrError e) { getErrorHandler().error(toCSSParseException(e)); } catch (final CSSParseException e) { getErrorHandler().error(e); } return sl; }
protected void displayMissingStyleSheet(String uri) { String message = NbBundle.getMessage(XhtmlCssEngine.class, "MissingStylesheet", // NOI18N uri); if (errorHandler != null) { // handleError(message, null, -1, 0, null); errorHandler.error(createCSSParseException(message, null, -1, 0, null)); } else { // OutputListener listener = null; // TODO - provide clickable errors // MarkupService.displayError(message, listener); // InSyncService.getProvider().getRaveErrorHandler().displayError(message); UserAgent userAgent = getUserAgent(); if (userAgent == null) { // XXX Log it? } else { userAgent.displayErrorForLocation(message, null, -1, -1); } } }
public void parseStyleSheet(final InputSource source) throws IOException { source_ = source; ReInit(getCharStream(source)); try { styleSheet(); } catch (final ParseException e) { getErrorHandler().error(toCSSParseException("invalidStyleSheet", e)); } catch (final TokenMgrError e) { getErrorHandler().error(toCSSParseException(e)); } catch (final CSSParseException e) { getErrorHandler().error(e); } }
public void parseRule(final InputSource source) throws IOException { source_ = source; ReInit(getCharStream(source)); try { styleSheetRuleSingle(); } catch (final ParseException e) { getErrorHandler().error(toCSSParseException("invalidRule", e)); } catch (final TokenMgrError e) { getErrorHandler().error(toCSSParseException(e)); } catch (final CSSParseException e) { getErrorHandler().error(e); } }
public LexicalUnit parsePropertyValue(final InputSource source) throws IOException { source_ = source; ReInit(getCharStream(source)); LexicalUnit lu = null; try { lu = expr(); } catch (final ParseException e) { getErrorHandler().error(toCSSParseException("invalidExpr", e)); } catch (final TokenMgrError e) { getErrorHandler().error(toCSSParseException(e)); } catch (final CSSParseException e) { getErrorHandler().error(e); } return lu; }
public boolean parsePriority(final InputSource source) throws IOException { source_ = source; ReInit(getCharStream(source)); boolean b = false; try { b = prio(); } catch (final ParseException e) { getErrorHandler().error(toCSSParseException("invalidPrio", e)); } catch (final TokenMgrError e) { getErrorHandler().error(toCSSParseException(e)); } catch (final CSSParseException e) { getErrorHandler().error(e); } return b; }
public SACMediaList parseMedia(final InputSource source) throws IOException { source_ = source; ReInit(getCharStream(source)); final SACMediaListImpl ml = new SACMediaListImpl(); try { mediaList(ml); } catch (final ParseException e) { getErrorHandler().error(toCSSParseException("invalidMediaList", e)); } catch (final TokenMgrError e) { getErrorHandler().error(toCSSParseException(e)); } catch (final CSSParseException e) { getErrorHandler().error(e); } return ml; }
protected void warnCircularReference(URL uri, Object location) { String message = NbBundle.getMessage(XhtmlCssEngine.class, "MSG_CircularReference", uri); // NOI18N if (errorHandler != null) { // handleError(message, location, -1, -1, null); errorHandler.error(createCSSParseException(message, location, -1, -1, null)); } else { // OutputListener listener = getListener(location, -1, -1); // MarkupService.displayError(message, listener); if (location instanceof AbstractValue) { location = ((AbstractValue)location).getLocation(); } // InSyncService.getProvider().getRaveErrorHandler().displayErrorForLocation(message, location, -1, -1); UserAgent userAgent = getUserAgent(); if (userAgent == null) { // XXX What to do now, log it? } else { userAgent.displayErrorForLocation(message, location, -1, -1); } } }
public void property(final String name, final LexicalUnit value, final boolean important, final Locator locator) { final CSSStyleDeclarationImpl decl = (CSSStyleDeclarationImpl) nodeStack_.peek(); try { final Property property = new Property(name, new CSSValueImpl(value), important); addLocator(locator, property); decl.addProperty(property); } catch (final DOMException e) { if (parser_ instanceof AbstractSACParser) { final AbstractSACParser parser = (AbstractSACParser) parser_; parser.getErrorHandler().error(parser.toCSSParseException(e)); } // call ErrorHandler? } }
final public void unknownAtRule() throws ParseException {String s; Locator locator; try { jj_consume_token(ATKEYWORD); locator = createLocator(token); s = skip(); handleIgnorableAtRule(s, locator); } catch (ParseException e) { getErrorHandler().error(toCSSParseException("invalidUnknownRule", e)); } }
final public void unknownAtRule() throws ParseException {String s; Locator locator; try { jj_consume_token(ATKEYWORD); locator = createLocator(token); s = skip(); handleIgnorableAtRule(s, locator); } catch (ParseException e) { getErrorHandler().error(toCSSParseException("invalidUnknownRule", e)); } }
final public void unknownAtRule() throws ParseException {String s; Locator locator; try { jj_consume_token(ATKEYWORD); locator = createLocator(token); s = skip(); handleIgnorableAtRule(s, locator); } catch (ParseException e) { getErrorHandler().error(toCSSParseException("invalidUnknownRule", e)); } }
final public void unknownAtRule() throws ParseException {String s; Locator locator; try { jj_consume_token(ATKEYWORD); locator = createLocator(token); s = skip(); handleIgnorableAtRule(s, locator); } catch (ParseException e) { getErrorHandler().error(toCSSParseException("invalidUnknownRule", e)); } }
final public void unknownAtRule() throws ParseException {String s; Locator locator; try { jj_consume_token(ATKEYWORD); locator = createLocator(token); s = skip(); handleIgnorableAtRule(s, locator); } catch (ParseException e) { getErrorHandler().error(toCSSParseException("invalidUnknownRule", generateParseException())); } }
final public void charsetRule() throws ParseException {Token t; Locator locator; try { jj_consume_token(CHARSET_SYM); locator = createLocator(token); jj_consume_token(S); t = jj_consume_token(STRING); jj_consume_token(SEMICOLON); handleCharset(t.toString(), locator); } catch (ParseException e) { getErrorHandler().error(toCSSParseException("invalidCharsetRule", e)); } }
final public void charsetRule() throws ParseException {Token t; Locator locator; try { jj_consume_token(CHARSET_SYM); locator = createLocator(token); jj_consume_token(S); t = jj_consume_token(STRING); jj_consume_token(SEMICOLON); handleCharset(t.toString(), locator); } catch (ParseException e) { getErrorHandler().error(toCSSParseException("invalidCharsetRule", e)); } }