org.richfaces.component.util

## Class HtmlUtil

- java.lang.Object
- - org.richfaces.component.util.HtmlUtil

-     public final class HtmlUtil
      extends Object

  Author:
    Nick Belaevski - nbelaevski@exadel.com created 09.02.2007, Brian Leathem

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static Pattern` | `ID_SELECTOR_PATTERN`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static String` | `addToSize(String declaration, String delta)`
    `static String` | `concatClasses(Object... classes)`
    `static String` | `concatStyles(Object... styles)`
    `static String` | `escapeHtml(String html)`
    `static String` | `expandIdSelector(String selector, javax.faces.component.UIComponent component, javax.faces.context.FacesContext context)` Expands ID selectors in given CSS selector from componentId to clientId.
    `static String` | `idsToIdSelector(String ids)`
    `static boolean` | `shouldWriteId(javax.faces.component.UIComponent component)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### ID_SELECTOR_PATTERN

          public static final Pattern ID_SELECTOR_PATTERN

  - ### Method Detail

    - #### addToSize

          public static String addToSize(String declaration,
                         String delta)

    - #### expandIdSelector

          public static String expandIdSelector(String selector,
                                javax.faces.component.UIComponent component,
                                javax.faces.context.FacesContext context)

      Expands ID selectors in given CSS selector from componentId to clientId.

      e.g. `#componentId` turns out into `#form:componentId`

      For expansion, `RendererUtils.findComponentFor(FacesContext, UIComponent, String)` is used.

      Parameters:
        `selector` - the CSS selector
        `component` - the root component for finding other components in tree
        `context` - the `FacesContext`
      Returns:
        The expanded CSS selector where ID selectors are expanded from componentIds to clientIds

    - #### idsToIdSelector

          public static String idsToIdSelector(String ids)

    - #### shouldWriteId

          public static boolean shouldWriteId(javax.faces.component.UIComponent component)

    - #### concatClasses

          public static String concatClasses(Object... classes)

    - #### concatStyles

          public static String concatStyles(Object... styles)

    - #### escapeHtml

          public static String escapeHtml(String html)

Copyright © 2014 JBoss by Red Hat. All Rights Reserved.