(element)
return namespace
Returns the element namespace string.
Returns the element namespace string.
Returns the element namespace string .
def _get_namespace(element):
  """Returns the element namespace string."""
  # The worldbody is treated as a member of the `body` namespace.
  if element.tag == 'worldbody':
    namespace = 'body'
  else:
    namespace = element.spec.namespace.split(constants.NAMESPACE_SEPARATOR)[0]
    # Mocap bodies have distinct attributes so we use a dummy namespace for
    # them.
    if namespace == 'body' and element.mocap == 'true':
      namespace = 'mocap_body'
  return namespace
def _get_namespace ( element ) : # The worldbody is treated as a member of the `body` namespace. if element . tag == 'worldbody' : namespace = 'body' else : namespace = element . spec . namespace . split ( constants . NAMESPACE_SEPARATOR ) [ 0 ] # Mocap bodies have distinct attributes so we use a dummy namespace for # them. if namespace == 'body' and element . mocap == 'true' : namespace = 'mocap_body' return namespace