code: protected void renderStringValue(final UIComponent component,
                                       final ResponseWriter writer,
                                       final String attributeName,
                                       final String matchingValue) throws IOException {
          if (component.getAttributes().get(attributeName) != null
                  && matchingValue.equalsIgnoreCase(component.getAttributes().get(attributeName).toString())
                  && shouldRenderAttribute(component.getAttributes().get(attributeName))) {
              writer.writeAttribute(attributeName, matchingValue, attributeName);
          }
      }
docs: Render string value if attribute is equals to matching value.
  
  @param attributeName attribute name
  @param component     the component
  @param writer        html response writer
  @param matchingValue matchingValue
  @throws IOException thrown by writer