The body of the request

@param body Request body in string form
505861
public PactDslRequestWithoutPath body(String body, ContentType mimeType) {
        return body(body, mimeType.toString());
    }
37875
private void addBodyToContext(final String body) {
        if(!body.isEmpty()) {
            final JSONParser parser = new JSONParser();
            try {
                final JSONObject json = (JSONObject) parser.parse(body);
                context.put("requestBody", json);
            } catch (final ParseException e) {
                e.printStackTrace();
            }
        }
    }
1347988
@Route(method= HttpMethod.POST, uri="/consume",
            accepts = "application/xml")
    public Result fromXML(@Body Data form) {
        return ok(form).xml();
    }
1352621
public PactDslRequestWithoutPath body(Document body) throws TransformerException {
        requestBody = OptionalBody.body(xmlToString(body).getBytes());
        if (!requestHeaders.containsKey(CONTENT_TYPE)) {
            requestHeaders.put(CONTENT_TYPE, Collections.singletonList(ContentType.APPLICATION_XML.toString()));
        }
        return this;
    }
513301
protected String getRequestBody(HttpServerExchange exchange) throws IOException {
        String body = "";
        if (RequestUtils.isPostPutPatch(exchange)) {
            exchange.startBlocking();
            body = IOUtils.toString(exchange.getInputStream(), Default.ENCODING.toString());
        }

        return body;
    }
1119622
public static String getContentTypeByRequestBody(String body) {
		final ContentType contentType = ContentType.get(body);
		return (null == contentType) ? null : contentType.toString();
	}
13314
private void prepareRequestBody() throws IOException {

    if (bodyByteArray != null) {
      setByteArrayBody();
    } else if (bodyString != null) {
      setStringBody();
    } else if (bodyObject != null) {
      setTypedBody();
    }
  }
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);
    }
1250770
public void setBody(String body)
    {
    	String xbody = body;
    	String [] row = xbody.split("\n");
    	for(int i=0; i<row.length; i++){
    		this.m_xbody.add(row[i]);
    	}
    }
950205
@SafeVarargs
    public final RequestBuilder body(Map.Entry<String, ?>... formBody) {
        return body(Lists.of(formBody));
    }
11375
public function setPostBody ($body)
    {
        if ($this->_sent) {
            throw new CAS_OutOfSequenceException(
                'Request has already been sent cannot '.__METHOD__
            );
        }
        if (!$this->isPost) {
            throw new CAS_OutOfSequenceException(
                'Cannot add a POST body to a GET request, use makePost() first.'
            );
        }

        $this->postBody = $body;
    }
954757
@Override
  public <X> void body(Class<X> type, Result<X> result)
  {
    delegate().body(type, result);
  }
316455
public final void methodBody() throws RecognitionException {
		int methodBody_StartIndex = input.index();

		try {
			if ( state.backtracking>0 && alreadyParsedRule(input, 59) ) { return; }

			// src/main/resources/org/drools/compiler/semantics/java/parser/Java.g:579:5: ( block )
			// src/main/resources/org/drools/compiler/semantics/java/parser/Java.g:579:7: block
			{
			pushFollow(FOLLOW_block_in_methodBody2106);
			block();
			state._fsp--;
			if (state.failed) return;
			}

		}
		catch (RecognitionException re) {
			reportError(re);
			recover(input,re);
		}
		finally {
			// do for sure before leaving
			if ( state.backtracking>0 ) { memoize(input, 59, methodBody_StartIndex); }

		}
	}
998120
@Route(method = HttpMethod.POST, uri = "/result")
    public Result hello(@Body MyForm form) {
        return ok(render(hello,
                ImmutableMap.<String, Object>of("form", form)));
    }
355144
public static String post(String url, String body) {
        return request(HttpRequest.post(replaceLocalHost(url)), body).body();
    }
239537
def _default_body(self):
        
        if not self.data:
            return ""
        if self.content_type == 'application/json':
            import json
            return json.dumps(self.data)
        elif self.content_type == 'application/x-www-form-urlencoded':
            import urllib
            return urllib.urlencode(self.data)
        else:
            raise NotImplementedError(
                "You must manually encode the request "
                "body for '{}'".format(self.content_type)
            )
571750
@Deprecated
  public RequestTemplate bodyTemplate(String bodyTemplate) {
    this.body(Request.Body.bodyTemplate(bodyTemplate, Util.UTF_8));
    return this;
  }