Generates a CAPTION tag with some content.

@param body content for the tag
@return an HtmlTree object for the CAPTION tag
761763
public static HtmlTree CAPTION(Content body) {
        HtmlTree htmltree = new HtmlTree(HtmlTag.CAPTION, nullCheck(body));
        return htmltree;
    }
227808
public static HtmlTree TR(Content body) {
        HtmlTree htmltree = new HtmlTree(HtmlTag.TR, nullCheck(body));
        return htmltree;
    }
542478
@Deprecated
  public RequestTemplate body(String bodyText) {
    byte[] bodyData = bodyText != null ? bodyText.getBytes(UTF_8) : null;
    return body(bodyData, UTF_8);
  }
621693
public void setBody(AstNode body) {
        this.body = body;
        int end = body.getPosition() + body.getLength();
        this.setLength(end - this.getPosition());
        body.setParent(this);
    }
1329878
public static <E extends HTMLElement> TextContentBuilder<E> textElement(String tag, Class<E> type) {
        return new TextContentBuilder<>(createElement(tag, type));
    }
1103012
public static HtmlTree SECTION(Content body) {
        HtmlTree htmltree = new HtmlTree(HtmlTag.SECTION, nullCheck(body));
        htmltree.setRole(Role.REGION);
        return htmltree;
    }
1095909
public static HtmlTree DL(Content body) {
        HtmlTree htmltree = new HtmlTree(HtmlTag.DL, nullCheck(body));
        return htmltree;
    }
1080049
public static HtmlTree CODE(Content body) {
        HtmlTree htmltree = new HtmlTree(HtmlTag.CODE, nullCheck(body));
        return htmltree;
    }
843271
@HtmlSafe
	public String getBodyHtml()
	{
		String body = execution.getResults().trim();

		return body.replaceAll("<html>", "").replaceAll("</html>", "");
	}
1117797
private Element parseContent(String content) {
		Document doc = Jsoup.parseBodyFragment(content);
		doc.outputSettings().charset(outputEncoding);
		return doc.body();
	}
1016950
public static HtmlTree A(HtmlVersion htmlVersion, String attr, Content body) {
        HtmlTree htmltree = new HtmlTree(HtmlTag.A);
        htmltree.addAttr((htmlVersion == HtmlVersion.HTML4)
                ? HtmlAttr.NAME
                : HtmlAttr.ID,
                nullCheck(attr));
        htmltree.addContent(nullCheck(body));
        return htmltree;
    }
934116
public static String objectJsonBody(Object body) {
		if (body instanceof String)
			return (String) body;
		String txt = "";
		try {
			txt = mapper.writeValueAsString(body);
		} catch (JsonProcessingException e) {
			log.error("objectJsonBody", e);
		}
		return txt;
	}
176035
public static HtmlTree HEADING(HtmlTag headingTag, Content body) {
        return HEADING(headingTag, false, null, body);
    }
1364544
function create_content (body) {
      var meta = create_meta_info(body.meta_title, body.meta_description, body.meta_sort);
      return meta + body.content;
    }
526217
Source getSourceFromBodyContent() throws JspTagException, SAXException, ParserConfigurationException {
        if (bodyContent == null) {
            throw new JspTagException(Resources.getMessage("TRANSFORM_BODY_IS_NULL"));
        }
        String s = bodyContent.getString();
        if (s == null) {
            throw new JspTagException(Resources.getMessage("TRANSFORM_BODY_CONTENT_IS_NULL"));
        }
        s = s.trim();
        if (s.length() == 0) {
            throw new JspTagException(Resources.getMessage("TRANSFORM_BODY_IS_EMPTY"));
        }
        return XmlUtil.newSAXSource(new StringReader(s), xmlSystemId, entityResolver);
    }
684636
def get_body_content(self):
        

        try:
            html_tree = parse_html_string(self.content)
        except:
            return ''

        html_root = html_tree.getroottree()

        if len(html_root.find('body')) != 0:
            body = html_tree.find('body')

            tree_str = etree.tostring(body, pretty_print=True, encoding='utf-8', xml_declaration=False)

            # this is so stupid
            if tree_str.startswith(six.b('<body>')):
                n = tree_str.rindex(six.b('</body>'))

                return tree_str[6:n]

            return tree_str

        return ''
890902
public <T> void writeBodyFromObject(T bodyAsObject, Charset charset) {
        @SuppressWarnings("unchecked")
        Class<T> clazz = (Class<T>)bodyAsObject.getClass();
        ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
        Writer outputWriter = new OutputStreamWriter(outputStream, charset);

        try {
            Marshaller marshaller = JAXBContext.newInstance(clazz).createMarshaller();
            if (clazz.isAnnotationPresent(XmlRootElement.class)) {
                marshaller.marshal(bodyAsObject, outputWriter);
            } else {
                String tagName = unCapitalizedClassName(clazz);
                JAXBElement<T> element = new JAXBElement<T>(new QName("", tagName), clazz, bodyAsObject);
                marshaller.marshal(element, outputWriter);
            }
        } catch (JAXBException e) {
            throw new RuntimeException(e);
        }

        byte[] bodyContent = outputStream.toByteArray();
        message.contentType(Message.APPLICATION_XML)
                .contentEncoding(charset.name());
        message.body(bodyContent);
    }