MCPcopy Create free account
hub / github.com/EasyIME/PIME / get_body_argument

Method get_body_argument

python/python3/tornado/web.py:474–491  ·  view source on GitHub ↗

Returns the value of the argument with the given name from the request body. If default is not provided, the argument is considered to be required, and we raise a `MissingArgumentError` if it is missing. If the argument appears in the url more than once, we return t

(
        self,
        name: str,
        default: Union[None, str, _ArgDefaultMarker] = _ARG_DEFAULT,
        strip: bool = True,
    )

Source from the content-addressed store, hash-verified

472 return self._get_arguments(name, self.request.arguments, strip)
473
474 def get_body_argument(
475 self,
476 name: str,
477 default: Union[None, str, _ArgDefaultMarker] = _ARG_DEFAULT,
478 strip: bool = True,
479 ) -> Optional[str]:
480 """Returns the value of the argument with the given name
481 from the request body.
482
483 If default is not provided, the argument is considered to be
484 required, and we raise a `MissingArgumentError` if it is missing.
485
486 If the argument appears in the url more than once, we return the
487 last value.
488
489 .. versionadded:: 3.2
490 """
491 return self._get_argument(name, default, self.request.body_arguments, strip)
492
493 def get_body_arguments(self, name: str, strip: bool = True) -> List[str]:
494 """Returns a list of the body arguments with the given name.

Callers

nothing calls this directly

Calls 1

_get_argumentMethod · 0.95

Tested by

no test coverage detected